diff options
Diffstat (limited to 'adapters/glib.h')
-rw-r--r-- | adapters/glib.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/adapters/glib.h b/adapters/glib.h index e0a6411..ad59dd1 100644 --- a/adapters/glib.h +++ b/adapters/glib.h @@ -134,6 +134,9 @@ redis_source_new (redisAsyncContext *ac) g_return_val_if_fail(ac != NULL, NULL); source = (RedisSource *)g_source_new(&source_funcs, sizeof *source); + if (source == NULL) + return NULL; + source->ac = ac; source->poll_fd.fd = c->fd; source->poll_fd.events = 0; |