aboutsummaryrefslogtreecommitdiff
path: root/src/fs/fs_publish.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2010-06-25 21:08:55 +0000
committerChristian Grothoff <christian@grothoff.org>2010-06-25 21:08:55 +0000
commit537903a8dc4c3ecf2dfa382af0289ddf890adfc7 (patch)
tree93e448c15c843861bd5dfe86c7cad3245abedfe7 /src/fs/fs_publish.c
parent2b61888a0bf1d41b2b25256ca9834c3040551ce9 (diff)
downloadgnunet-537903a8dc4c3ecf2dfa382af0289ddf890adfc7.tar.gz
gnunet-537903a8dc4c3ecf2dfa382af0289ddf890adfc7.zip
fixing common off-by-one error with respect to maximum message size
Diffstat (limited to 'src/fs/fs_publish.c')
-rw-r--r--src/fs/fs_publish.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/fs/fs_publish.c b/src/fs/fs_publish.c
index 2ebb96169..13701405e 100644
--- a/src/fs/fs_publish.c
+++ b/src/fs/fs_publish.c
@@ -761,7 +761,7 @@ hash_for_index_cb (void *cls,
761 fn = GNUNET_STRINGS_filename_expand (p->filename); 761 fn = GNUNET_STRINGS_filename_expand (p->filename);
762 GNUNET_assert (fn != NULL); 762 GNUNET_assert (fn != NULL);
763 slen = strlen (fn) + 1; 763 slen = strlen (fn) + 1;
764 if (slen > GNUNET_SERVER_MAX_MESSAGE_SIZE - sizeof(struct IndexStartMessage)) 764 if (slen >= GNUNET_SERVER_MAX_MESSAGE_SIZE - sizeof(struct IndexStartMessage))
765 { 765 {
766 GNUNET_log (GNUNET_ERROR_TYPE_WARNING, 766 GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
767 _("Can not index file `%s': %s. Will try to insert instead.\n"), 767 _("Can not index file `%s': %s. Will try to insert instead.\n"),