diff options
author | Mark Nunberg <mnunberg@haskalah.org> | 2019-02-11 11:26:15 -0500 |
---|---|---|
committer | Mark Nunberg <mnunberg@haskalah.org> | 2019-02-20 09:11:10 -0500 |
commit | 5f633ac4ec0ee818fb9785e751fbbdfab48f9542 (patch) | |
tree | 7d666856e75c9b821343aa7ad1c796839bdf6f5e | |
parent | 0bc2356ed5b587f4b4e41878a51b741e12901016 (diff) | |
download | hiredict-5f633ac4ec0ee818fb9785e751fbbdfab48f9542.tar.xz |
fix potential uninitialized read
If callback was set before scheduleTimer was set (i..e before one of the
attach()) calls.
-rw-r--r-- | async.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -144,6 +144,7 @@ static redisAsyncContext *redisAsyncInitialize(redisContext *c) { ac->ev.addWrite = NULL; ac->ev.delWrite = NULL; ac->ev.cleanup = NULL; + ac->ev.scheduleTimer = NULL; ac->onConnect = NULL; ac->onDisconnect = NULL; @@ -844,4 +845,4 @@ void redisAsyncSetTimeout(redisAsyncContext *ac, struct timeval tv) { } *ac->c.timeout = tv; -}
\ No newline at end of file +} |