aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBart Polot <bart@net.in.tum.de>2012-10-26 18:30:39 +0000
committerBart Polot <bart@net.in.tum.de>2012-10-26 18:30:39 +0000
commitef6f05f63769263a5201636c4b7f71eaa455cdf3 (patch)
tree261d9b1f53f2d74c1eccc9b6bc66b690164e25d6
parentc5e6fb548d324236859281e1f421986b36ba131a (diff)
downloadgnunet-ef6f05f63769263a5201636c4b7f71eaa455cdf3.tar.gz
gnunet-ef6f05f63769263a5201636c4b7f71eaa455cdf3.zip
- fixed regex offset, doc
-rw-r--r--src/mesh/gnunet-service-mesh.c5
-rw-r--r--src/mesh/mesh_api.c2
2 files changed, 5 insertions, 2 deletions
diff --git a/src/mesh/gnunet-service-mesh.c b/src/mesh/gnunet-service-mesh.c
index 5cc0d8c0d..1030fec59 100644
--- a/src/mesh/gnunet-service-mesh.c
+++ b/src/mesh/gnunet-service-mesh.c
@@ -6733,10 +6733,13 @@ handle_local_announce_regex (void *cls, struct GNUNET_SERVER_Client *client,
6733 msg = (struct GNUNET_MESH_RegexAnnounce *) message; 6733 msg = (struct GNUNET_MESH_RegexAnnounce *) message;
6734 len = ntohs (message->size) - sizeof(struct GNUNET_MESH_RegexAnnounce); 6734 len = ntohs (message->size) - sizeof(struct GNUNET_MESH_RegexAnnounce);
6735 regex = GNUNET_malloc (len + 1); 6735 regex = GNUNET_malloc (len + 1);
6736 memcpy (regex, &message[1], len); 6736 memcpy (regex, &msg[1], len);
6737 regex[len] = '\0'; 6737 regex[len] = '\0';
6738 rd.regex = regex; 6738 rd.regex = regex;
6739 rd.compression = ntohs (msg->compression_characters); 6739 rd.compression = ntohs (msg->compression_characters);
6740 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " length %u\n", len);
6741 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " regex %s\n", regex);
6742 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " cm %u\n", ntohs(rd.compression));
6740 GNUNET_array_append (c->regexes, c->n_regex, rd); 6743 GNUNET_array_append (c->regexes, c->n_regex, rd);
6741 if (GNUNET_SCHEDULER_NO_TASK == c->regex_announce_task) 6744 if (GNUNET_SCHEDULER_NO_TASK == c->regex_announce_task)
6742 { 6745 {
diff --git a/src/mesh/mesh_api.c b/src/mesh/mesh_api.c
index 77ae1217f..bef8ecae3 100644
--- a/src/mesh/mesh_api.c
+++ b/src/mesh/mesh_api.c
@@ -1152,7 +1152,7 @@ process_incoming_data (struct GNUNET_MESH_Handle *h,
1152 LOG (GNUNET_ERROR_TYPE_DEBUG, " pid %u\n", pid); 1152 LOG (GNUNET_ERROR_TYPE_DEBUG, " pid %u\n", pid);
1153 if (NULL == t) 1153 if (NULL == t)
1154 { 1154 {
1155 /* Tunnel was ignored, probably service didn't get it yet */ 1155 /* Tunnel was ignored/destroyed, probably service didn't get it yet */
1156 LOG (GNUNET_ERROR_TYPE_DEBUG, " ignored!\n"); 1156 LOG (GNUNET_ERROR_TYPE_DEBUG, " ignored!\n");
1157 return GNUNET_YES; 1157 return GNUNET_YES;
1158 } 1158 }