diff options
author | Pieter Noordhuis <pcnoordhuis@gmail.com> | 2014-04-09 22:56:16 -0700 |
---|---|---|
committer | Pieter Noordhuis <pcnoordhuis@gmail.com> | 2014-04-09 22:56:16 -0700 |
commit | 8332a88393cc79b6f7d431859e5bbf157d8c1ea3 (patch) | |
tree | e23037a09827d0a27cee0d3cc5a188c0742f12f3 | |
parent | a9c21e4d48ecde49901e46e78ae87897fc182d52 (diff) | |
download | hiredict-8332a88393cc79b6f7d431859e5bbf157d8c1ea3.tar.xz |
File descriptors can be 0
-rw-r--r-- | net.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -55,7 +55,7 @@ void __redisSetError(redisContext *c, int type, const char *str); static void redisContextCloseFd(redisContext *c) { - if (c && c->fd > 0) { + if (c && c->fd >= 0) { close(c->fd); c->fd = -1; } |