From e4a4e20e8cf19dd9b24230199e8bdac36827ec6b Mon Sep 17 00:00:00 2001 From: Andrea Mazzoleni Date: Fri, 11 Jul 2014 18:49:22 +0200 Subject: [PATCH] Ensures to always write not zero data in the regression test. --- cmdline/mktest.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cmdline/mktest.c b/cmdline/mktest.c index 2100ef43..e1f9077d 100644 --- a/cmdline/mktest.c +++ b/cmdline/mktest.c @@ -268,7 +268,7 @@ void writ(const char* path, int size) /* write garbage, in case also over the end */ count = size; while (count) { - fputc(rnd(256), f); + fputc(rndnotzero(256), f); --count; } @@ -347,7 +347,7 @@ void damage(const char* path, int size) unsigned char c; do { - c = rnd(256); + c = rndnotzero(256); } while (c == data[i]); data[i] = c; @@ -410,7 +410,7 @@ void append(const char* path, int size) /* write garbage, in case also over the end */ count = rnd(size); while (count) { - fputc(rnd(256), f); + fputc(rndnotzero(256), f); --count; }