X-Git-Url: https://git.cworth.org/git?p=obsolete%2Fnotmuch-old;a=blobdiff_plain;f=test%2Frandom-corpus.c;h=8b7748ef28010535104225f33350b3927df32134;hp=f354d4b92c9f9e82d5cdccf6aa9360c3e729dc28;hb=d08c714b6a172cf0018bee4f60aff069d5508d4e;hpb=7c3a995d6b6e066aa68b0adf0433f45cb3812c2a diff --git a/test/random-corpus.c b/test/random-corpus.c index f354d4b9..8b7748ef 100644 --- a/test/random-corpus.c +++ b/test/random-corpus.c @@ -96,7 +96,9 @@ random_utf8_string (void *ctx, size_t char_count) buf = talloc_realloc (ctx, buf, gchar, buf_size); } - randomchar = random_unichar (); + do { + randomchar = random_unichar (); + } while (randomchar == '\n'); written = g_unichar_to_utf8 (randomchar, buf + offset);