X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fnetwork.c;h=219f163eadbac1030f5b8f652cf1eaf9090d11f8;hb=c89182b424bb4184bd7da3f2ab687b542ed7eea3;hp=ccd033b1c6476484a34751b0d8f1d28ed6256ca5;hpb=92cc06313a65f9b48172d4d3f776b7205e54798d;p=collectd.git diff --git a/src/network.c b/src/network.c index ccd033b1..219f163e 100644 --- a/src/network.c +++ b/src/network.c @@ -36,9 +36,6 @@ #include "network.h" -#if HAVE_PTHREAD_H -# include -#endif #if HAVE_NETDB_H # include #endif @@ -56,7 +53,6 @@ #endif #if HAVE_LIBGCRYPT -# include # if defined __APPLE__ /* default xcode compiler throws warnings even when deprecated functionality * is not used. -Werror breaks the build because of erroneous warnings. @@ -934,7 +930,7 @@ static int parse_part_string (void **ret_buffer, size_t *ret_buffer_len, uint16_t pkg_length; size_t payload_size; - if (output_len <= 0) + if (output_len == 0) return (EINVAL); if (buffer_len < header_size)