aboutsummaryrefslogtreecommitdiffstats
path: root/src/song_print.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2010-05-18 23:54:03 +0200
committerMax Kellermann <max@duempel.org>2010-05-18 23:54:12 +0200
commit0a9b0dd07049b644a10ee920497a163ce6e23967 (patch)
treed66c77a50f1c15c7563cd8062edbde7db90aa214 /src/song_print.c
parent6aa0f61e15c1410e122096bc781a9443e4017385 (diff)
downloadmpd-0a9b0dd07049b644a10ee920497a163ce6e23967.tar.gz
mpd-0a9b0dd07049b644a10ee920497a163ce6e23967.tar.xz
mpd-0a9b0dd07049b644a10ee920497a163ce6e23967.zip
command: fallback strftime() formats on WIN32
On WIN32, "%F" and "%T" are not implemented.
Diffstat (limited to '')
-rw-r--r--src/song_print.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/song_print.c b/src/song_print.c
index 831688483..034c1d013 100644
--- a/src/song_print.c
+++ b/src/song_print.c
@@ -79,7 +79,13 @@ song_print_info(struct client *client, struct song *song)
if (tm2 != NULL) {
char timestamp[32];
- strftime(timestamp, sizeof(timestamp), "%FT%TZ", tm2);
+ strftime(timestamp, sizeof(timestamp),
+#ifdef G_OS_WIN32
+ "%Y-%m-%dT%H:%M:%SZ",
+#else
+ "%FT%TZ",
+#endif
+ tm2);
client_printf(client, "Last-Modified: %s\n",
timestamp);
}