diff options
author | Roland McGrath <roland@gnu.org> | 1994-04-01 22:48:31 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1994-04-01 22:48:31 +0000 |
commit | 02c33abade3af7cffc7be114ba0faf328f241e80 (patch) | |
tree | 96c3a7b97b7c46121cb03909738aff207c198d7f /fstests | |
parent | 7e716dee4b4ccdf0e2f711716dd71178ec37c083 (diff) |
Formerly fstests.c.~19~
Diffstat (limited to 'fstests')
-rw-r--r-- | fstests/fstests.c | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/fstests/fstests.c b/fstests/fstests.c index aaa6f6d9..09ac9ba3 100644 --- a/fstests/fstests.c +++ b/fstests/fstests.c @@ -60,14 +60,22 @@ main () printf ("Error on sync: %d\n", err); #else - unlink ("/newdir"); - rmdir ("/newdir"); - mkdir ("/newdir", 0777); - rename ("/newdir", "/newdir2"); - rmdir ("/foo"); - mkdir ("/foo", 0777); - rename ("/newdir2", "/foo"); - sync (); + if (unlink ("/newdir")) + perror ("unlink"); + if (rmdir ("/newdir")) + perror ("1st rmdir"); + if (mkdir ("/newdir", 0777)) + perror ("1st mkdir"); + if (rename ("/newdir", "/newdir2")) + perror ("1st rename"); + if (rmdir ("/foo")) + perror ("2nd rmdir"); + if (mkdir ("/foo", 0777)) + perror ("2nd mkdir"); + if (rename ("/newdir2", "/foo")) + perror ("2nd rename"); + if (sync ()) + perror ("sync"); #endif printf ("All done.\n"); |