]> git.ipfire.org Git - thirdparty/collectd.git/commitdiff
network plugin: Simplify initialization of sockent_t. 3543/head
authorFlorian Forster <octo@collectd.org>
Sun, 30 Aug 2020 07:19:39 +0000 (09:19 +0200)
committerFlorian Forster <octo@collectd.org>
Sun, 30 Aug 2020 07:19:39 +0000 (09:19 +0200)
src/network_test.c

index ce3469a54c6210800a05a987ad5a2e17cb931dbc..0f93d17bcd9b4748aa328e211050451ee36a81d6 100644 (file)
@@ -224,17 +224,7 @@ static int decode_string(char const *in, uint8_t *out, size_t *out_size) {
 }
 
 DEF_TEST(parse_packet) {
-  sockent_t se
-#if HAVE_GCRYPT_H
-      = {.data.server =
-             (struct sockent_server){
-                 .cypher = NULL,
-                 .userdb = NULL,
-                 .security_level = SECURITY_LEVEL_NONE,
-             },
-        }
-#endif
-  ;
+  sockent_t se = {0};
 
   for (size_t i = 0; i < sizeof(raw_packet_data) / sizeof(raw_packet_data[0]);
        i++) {