summaryrefslogtreecommitdiffstats
path: root/disk-utils
diff options
context:
space:
mode:
Diffstat (limited to 'disk-utils')
-rw-r--r--disk-utils/fsck.cramfs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/disk-utils/fsck.cramfs.c b/disk-utils/fsck.cramfs.c
index 76ed303b0..ee9c20ab2 100644
--- a/disk-utils/fsck.cramfs.c
+++ b/disk-utils/fsck.cramfs.c
@@ -416,10 +416,10 @@ static void do_uncompress(char *path, int outfd, unsigned long offset,
curr = next;
} while (size);
}
-
+#include <utime.h>
static void change_file_status(char *path, struct cramfs_inode *i)
{
- const struct timeval epoch = { 0, 0 };
+ const struct timeval epoch[] = { {0,0}, {0,0} };
if (euid == 0) {
if (lchown(path, i->uid, i->gid) < 0)
@@ -431,7 +431,7 @@ static void change_file_status(char *path, struct cramfs_inode *i)
}
if (S_ISLNK(i->mode))
return;
- if (utimes(path, &epoch) < 0)
+ if (utimes(path, epoch) < 0)
err(FSCK_EX_ERROR, _("utimes failed: %s"), path);
}