projects
/
notmuch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7878175
)
Add missing null terminator before using byte-array contents as string.
author
Carl Worth
<cworth@cworth.org>
Wed, 14 Oct 2009 22:55:07 +0000
(15:55 -0700)
committer
Carl Worth
<cworth@cworth.org>
Wed, 14 Oct 2009 22:55:07 +0000
(15:55 -0700)
Thanks to valgrind for spotting this one.
notmuch-index-message.cc
patch
|
blob
|
history
diff --git
a/notmuch-index-message.cc
b/notmuch-index-message.cc
index 852f4e16259fba6fee4d5e51918f856a4c6702b4..3bb62f659dcdc29515bb03c616a56db569b586a3 100644
(file)
--- a/
notmuch-index-message.cc
+++ b/
notmuch-index-message.cc
@@
-436,6
+436,7
@@
gen_terms_part (Xapian::TermGenerator term_gen,
g_object_unref (stream);
+ g_byte_array_append (byte_array, (guint8 *) "\0", 1);
body = (char *) g_byte_array_free (byte_array, FALSE);
gen_terms_body_str (term_gen, body);