projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix for #477: Notification time gone wrong
[collectd.git]
/
src
/
memcached.c
diff --git
a/src/memcached.c
b/src/memcached.c
index
a09f45e
..
2a5e0f0
100644
(file)
--- a/
src/memcached.c
+++ b/
src/memcached.c
@@
-84,6
+84,15
@@
static int memcached_connect_unix (memcached_t *st)
return (-1);
}
return (-1);
}
+ /* connect to the memcached daemon */
+ int status = connect (fd, (struct sockaddr *)&serv_addr, sizeof(serv_addr));
+ if (status != 0)
+ {
+ shutdown (fd, SHUT_RDWR);
+ close (fd);
+ fd = -1;
+ }
+
return (fd);
} /* int memcached_connect_unix */
return (fd);
} /* int memcached_connect_unix */