summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2018-02-24 22:27:15 +0100
committerMax Kellermann <max@musicpd.org>2018-02-24 22:44:42 +0100
commitf3e683bd6ff464295826e2e760c7a67588038a04 (patch)
treed6f5db999a955861e75ab5199fc91137b89b1511 /test
parent50ce0c0d9d8f34bb8bd4a45152cff5da803710d5 (diff)
test/run_storage: fallback for %F on Windows
Diffstat (limited to 'test')
-rw-r--r--test/run_storage.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/run_storage.cxx b/test/run_storage.cxx
index ba889283f..a86444dd5 100644
--- a/test/run_storage.cxx
+++ b/test/run_storage.cxx
@@ -71,7 +71,12 @@ Ls(Storage &storage, const char *path)
char mtime_buffer[32];
const char *mtime = " ";
if (info.mtime > 0) {
- strftime(mtime_buffer, sizeof(mtime_buffer), "%F",
+ strftime(mtime_buffer, sizeof(mtime_buffer),
+#ifdef _WIN32
+ "%Y-%m-%d",
+#else
+ "%F",
+#endif
gmtime(&info.mtime));
mtime = mtime_buffer;
}