Skip to content

Commit

Permalink
set_t while free_cell callbacks are running
Browse files Browse the repository at this point in the history
  • Loading branch information
vladpaiu committed Oct 18, 2024
1 parent 3df04c7 commit e2abed9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions modules/tm/h_table.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ void free_cell( struct cell* dead_cell )
struct sip_msg *rpl;
struct totag_elem *tt, *foo;
struct proxy_l *p;
struct cell *backup_t;

backup_t = get_t();
set_t(dead_cell);

if ( has_tran_tmcbs( dead_cell, TMCB_TRANS_DELETED) )
run_trans_callbacks( TMCB_TRANS_DELETED, dead_cell, 0, 0, 0);
Expand All @@ -128,6 +132,8 @@ void free_cell( struct cell* dead_cell )

context_destroy(CONTEXT_TRAN, context_of(dead_cell));

set_t(backup_t);

release_cell_lock( dead_cell );

shm_lock();
Expand Down

0 comments on commit e2abed9

Please sign in to comment.