summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b37ddef)
raw | patch | inline | side by side (parent: b37ddef)
author | Florian Forster <octo@collectd.org> | |
Wed, 17 Jun 2015 05:50:46 +0000 (07:50 +0200) | ||
committer | Florian Forster <octo@collectd.org> | |
Wed, 17 Jun 2015 05:53:20 +0000 (07:53 +0200) |
I have the feeling that initialization via memset() and unions in the sockent
structure confuse clang's scan-build.
structure confuse clang's scan-build.
src/network.c | patch | blob | history |
diff --git a/src/network.c b/src/network.c
index 5d485ba3a23894a844d771336313dc9f4b693015..c5fd256f135c6b83e1a9eea749bd5752cf61b61d 100644 (file)
--- a/src/network.c
+++ b/src/network.c
if (type == SOCKENT_TYPE_SERVER)
{
se->data.server.fd = NULL;
+ se->data.server.fd_num = 0;
#if HAVE_LIBGCRYPT
se->data.server.security_level = SECURITY_LEVEL_NONE;
se->data.server.auth_file = NULL;
if (se == NULL)
return (-1);
+ assert (se->data.server.fd == NULL);
+ assert (se->data.server.fd_num == 0);
+
node = se->node;
service = se->service;