diff options
author | not-a-robot <not-a-robot@rediger.net> | 2016-12-09 11:12:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-12-09 11:12:16 +0100 |
commit | b4f9fc1a2aa1d991b014b03b0369fd36a089e39c (patch) | |
tree | 71b1029fbb1fb843aaf585720dfff8cbea47210f /dict.h | |
parent | 8636d90821f9656c62e92e78d93a380fc00fc0f7 (diff) | |
parent | cbb956567b715acd3022eb07a46eb6e23cd038e1 (diff) |
Auto merge of #468 - paul-scott:master, r=badboy
Prevented uv adapter from calling write when context has been freed
The `redisLibuvPoll` function can be called with both the `UV_READABLE` and `UV_WRITABLE` flags set at the same time. Calling `redisAsyncHandleRead` can lead to a disconnect and the context being cleaned up/freed. If this happens then `redisAsyncHandleWrite` should not be called otherwise memory read/write errors and duplicate freeing will occur.
These changes prevent this from happening by having the `redisLibuvCleanup` callback indicate that the context has been cleaned. This is done indirectly by setting the context to a null pointer, maybe someone can come up with a cleaner way.
Diffstat (limited to 'dict.h')
0 files changed, 0 insertions, 0 deletions