- log errors only when they are errors
authorBart Polot <bart@net.in.tum.de>
Tue, 18 Sep 2012 13:22:30 +0000 (13:22 +0000)
committerBart Polot <bart@net.in.tum.de>
Tue, 18 Sep 2012 13:22:30 +0000 (13:22 +0000)
src/mesh/gnunet-service-mesh.c

index 5f47c50d1f10181a12cf0021a2114d3898754056..e185d0cd4948d95c976e4ab528ebb9b6ac2e2808 100644 (file)
@@ -1335,11 +1335,13 @@ regex_next_edge (const struct MeshRegexBlock *block,
   struct MeshRegexSearchInfo *info = ctx->info;
   struct GNUNET_DHT_GetHandle *get_h;
 
+  int result;
+
   /* Find the longest match for the current string position, 
    * among tokens in the given block */
-  GNUNET_break (GNUNET_OK ==
-                GNUNET_MESH_regex_block_iterate (block, size,
-                                                 &regex_edge_iterator, ctx));
+  result = GNUNET_MESH_regex_block_iterate (block, size,
+                                            &regex_edge_iterator, ctx);
+  GNUNET_break (GNUNET_OK == result || SIZE_MAX == size);
 
   new_ctx = GNUNET_malloc (sizeof (struct MeshRegexSearchContext));
   new_ctx->info = info;