Skip to content

Commit

Permalink
Acquire the lock for modules that don't acquire it before calling lik…
Browse files Browse the repository at this point in the history
…e they are supposed to
  • Loading branch information
JohnSully committed Aug 29, 2019
1 parent bf905a7 commit f83a89f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/module.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3920,7 +3920,9 @@ RedisModuleCtx *RM_GetThreadSafeContext(RedisModuleBlockedClient *bc) {

/* Release a thread safe context. */
void RM_FreeThreadSafeContext(RedisModuleCtx *ctx) {
moduleAcquireGIL(false /*fServerThread*/);
moduleFreeContext(ctx);
moduleReleaseGIL(false /*fServerThread*/);
zfree(ctx);
}

Expand Down

0 comments on commit f83a89f

Please sign in to comment.