From 77624db04226cb19a34aaf1144c8fc8a00310b00 Mon Sep 17 00:00:00 2001 From: adilger Date: Fri, 18 Jul 2003 06:50:15 +0000 Subject: [PATCH] Fix POSIX write/getattr failure. --- lustre/tests/small_write.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lustre/tests/small_write.c b/lustre/tests/small_write.c index 8234450..5bc2d95 100644 --- a/lustre/tests/small_write.c +++ b/lustre/tests/small_write.c @@ -53,7 +53,8 @@ int main (int argc, char **argv) { memcpy(str2+(bytes/2), str, bytes); str2[lbytes] = '\0'; - printf("First String: %s\nSecond String: %s\n", str, str2); + if (bytes < 320) + printf("First String: %s\nSecond String: %s\n", str, str2); fd = open(argv[1], O_CREAT|O_RDWR|O_TRUNC, 0700); if (fd == -1) { @@ -121,7 +122,8 @@ int main (int argc, char **argv) { if (fd == -1) return 1; - printf("%s\n%s\n", readbuf, str2); + if (bytes < 320) + printf("%s\n%s\n", readbuf, str2); if (strcmp(readbuf, str2)) { printf("No match!\n"); return 1; -- 1.8.3.1