aboutsummaryrefslogtreecommitdiff
path: root/src/core/core_api.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-07-08 17:20:23 +0000
committerChristian Grothoff <christian@grothoff.org>2016-07-08 17:20:23 +0000
commitd8c53b12a818ff7cf82d06a1a69c395bdef85ee6 (patch)
tree0ebb0db416c157fcfde51a941185819dd12d51fd /src/core/core_api.c
parent5184c17d32a39c928c2a0fec3ee1ad098bbaa562 (diff)
downloadgnunet-d8c53b12a818ff7cf82d06a1a69c395bdef85ee6.tar.gz
gnunet-d8c53b12a818ff7cf82d06a1a69c395bdef85ee6.zip
-avoid calling memcpy() with NULL argument, even if len is 0
Diffstat (limited to 'src/core/core_api.c')
-rw-r--r--src/core/core_api.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/core_api.c b/src/core/core_api.c
index 86c9d38a2..dd912ac22 100644
--- a/src/core/core_api.c
+++ b/src/core/core_api.c
@@ -891,7 +891,7 @@ GNUNET_CORE_connect (const struct GNUNET_CONFIGURATION_Handle *cfg,
891 h->handlers = GNUNET_new_array (hcnt + 1, 891 h->handlers = GNUNET_new_array (hcnt + 1,
892 struct GNUNET_CORE_MessageHandler); 892 struct GNUNET_CORE_MessageHandler);
893 if (NULL != handlers) 893 if (NULL != handlers)
894 memcpy (h->handlers, 894 GNUNET_memcpy (h->handlers,
895 handlers, 895 handlers,
896 hcnt * sizeof (struct GNUNET_CORE_MessageHandler)); 896 hcnt * sizeof (struct GNUNET_CORE_MessageHandler));
897 h->hcnt = hcnt; 897 h->hcnt = hcnt;