Skip to content

Commit

Permalink
tsilo: don't execute tm callback for TMCB_DESTROY if server shutdowns
Browse files Browse the repository at this point in the history
- tsilo mod_destroy will clean up, otherwise may end up in deadlock at
  shutdown, when a slot lock is already aquired and the callback will
  try to aquire again
  • Loading branch information
miconda committed Mar 1, 2016
1 parent 87027c6 commit 81ec422
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions modules/tsilo/ts_handlers.c
Expand Up @@ -21,6 +21,8 @@

#include <string.h>

#include "../../sr_module.h"

#include "ts_hash.h"
#include "ts_handlers.h"

Expand Down Expand Up @@ -63,6 +65,7 @@ void ts_onreply(struct cell* t, int type, struct tmcb_params *param)
ts_transaction_t *cb_ptr, *ptr;

if(t_table==0) return;
if((type & (TMCB_DESTROY)) && destroy_modules_phase()) return;

cb_ptr = (ts_transaction_t*)(*param->param);
if (cb_ptr == NULL) {
Expand Down

0 comments on commit 81ec422

Please sign in to comment.