Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix libio/tst-atime not to presume ST_NOATIME exists.
  • Loading branch information
Roland McGrath committed Feb 6, 2015
1 parent 56606ab commit b65c0ff
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
@@ -1,5 +1,8 @@
2015-02-06 Roland McGrath <roland@hack.frob.com>

* libio/tst-atime.c (do_test): Move local variables SV and E
inside [ST_NOATIME] conditional.

* dirent/tst-fdopendir.c (O_NOATIME): If not defined, #define to 0.

* nptl/tst-kill5.c (do_test): Use INT_MAX rather than SIGRTMAX + 10.
Expand Down
5 changes: 2 additions & 3 deletions libio/tst-atime.c
Expand Up @@ -23,8 +23,6 @@ do_test (void)
int ch;
struct stat st1;
struct stat st2;
struct statvfs sv;
int e;

buf = (char *) malloc (strlen (test_dir) + sizeof "/tst-atime.XXXXXX");
if (buf == NULL)
Expand All @@ -44,7 +42,8 @@ do_test (void)
#ifdef ST_NOATIME
/* Make sure the filesystem doesn't have the noatime option set. If
statvfs is not available just continue. */
e = fstatvfs (fd, &sv);
struct statvfs sv;
int e = fstatvfs (fd, &sv);
if (e != ENOSYS)
{
if (e != 0)
Expand Down

0 comments on commit b65c0ff

Please sign in to comment.