libarchive: Do not use ST_NOATIME if not defined

Use the same pattern already used elsewhere in archive_read_disk_posix.c
to use ST_NOATIME only when defined.
This commit is contained in:
Brad King 2011-12-22 16:36:14 -05:00
parent 680fc0eda8
commit 8b7ee30bf4
1 changed files with 2 additions and 0 deletions

View File

@ -1390,9 +1390,11 @@ setup_current_filesystem(struct archive_read_disk *a)
else
t->current_filesystem->remote = 1;
#if defined(ST_NOATIME)
if (sfs.f_flag & ST_NOATIME)
t->current_filesystem->noatime = 1;
else
#endif
t->current_filesystem->noatime = 0;
/* Set maximum filename length. */