diff options
author | Christian Grothoff <christian@grothoff.org> | 2010-10-20 11:49:09 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2010-10-20 11:49:09 +0000 |
commit | 1f69531ec9d9b5d9046895f8c6b0b590185ac17d (patch) | |
tree | 7d753f6c40b393b0029360c4a348bad2300ed3e8 /src/core | |
parent | 63658b57fbf8c475f4fa15c61a262a557b5314bc (diff) | |
download | gnunet-1f69531ec9d9b5d9046895f8c6b0b590185ac17d.tar.gz gnunet-1f69531ec9d9b5d9046895f8c6b0b590185ac17d.zip |
initialize reserved field, check it
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/core_api.c | 1 | ||||
-rw-r--r-- | src/core/gnunet-service-core.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/src/core/core_api.c b/src/core/core_api.c index 6d492537d..453ca1f21 100644 --- a/src/core/core_api.c +++ b/src/core/core_api.c | |||
@@ -607,6 +607,7 @@ init_reply_handler (void *cls, const struct GNUNET_MessageHeader *msg) | |||
607 | return; | 607 | return; |
608 | } | 608 | } |
609 | m = (const struct InitReplyMessage *) msg; | 609 | m = (const struct InitReplyMessage *) msg; |
610 | GNUNET_break (0 == ntohl (m->reserved)); | ||
610 | /* start our message processing loop */ | 611 | /* start our message processing loop */ |
611 | #if DEBUG_CORE | 612 | #if DEBUG_CORE |
612 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 613 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
diff --git a/src/core/gnunet-service-core.c b/src/core/gnunet-service-core.c index 52f229b01..c0213f337 100644 --- a/src/core/gnunet-service-core.c +++ b/src/core/gnunet-service-core.c | |||
@@ -1045,6 +1045,7 @@ handle_client_init (void *cls, | |||
1045 | /* send init reply message */ | 1045 | /* send init reply message */ |
1046 | irm.header.size = htons (sizeof (struct InitReplyMessage)); | 1046 | irm.header.size = htons (sizeof (struct InitReplyMessage)); |
1047 | irm.header.type = htons (GNUNET_MESSAGE_TYPE_CORE_INIT_REPLY); | 1047 | irm.header.type = htons (GNUNET_MESSAGE_TYPE_CORE_INIT_REPLY); |
1048 | irm.reserved = htonl (0); | ||
1048 | memcpy (&irm.publicKey, | 1049 | memcpy (&irm.publicKey, |
1049 | &my_public_key, | 1050 | &my_public_key, |
1050 | sizeof (struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded)); | 1051 | sizeof (struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded)); |