use utimes() rather than obsolescent utime()
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
diff --git a/archival/libunarchive/data_extract_all.c b/archival/libunarchive/data_extract_all.c
index 0d529a6..889face 100644
--- a/archival/libunarchive/data_extract_all.c
+++ b/archival/libunarchive/data_extract_all.c
@@ -143,9 +143,9 @@
}
/* same for utime */
if (archive_handle->ah_flags & ARCHIVE_RESTORE_DATE) {
- struct utimbuf t;
- t.actime = t.modtime = file_header->mtime;
- utime(file_header->name, &t);
+ struct timeval t = {.tv_sec = file_header->mtime,
+ .tv_usec = 0};
+ utimes(file_header->name, &t);
}
}
}