summaryrefslogtreecommitdiff
path: root/src/command/StorageCommands.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2017-02-11 22:47:05 +0100
committerMax Kellermann <max@musicpd.org>2017-02-11 23:45:15 +0100
commit6636c69a11e8b4d8aa079d86ef89fb8dbf96964e (patch)
treec12f3b7fc987ca4fe165603f7c333d2b09dfa46c /src/command/StorageCommands.cxx
parent0ccaf4a1fff8933b28312d40ccf45a2a9fae2018 (diff)
storage/FileInfo: convert mtime to std::chrono::system_clock::time_point
Diffstat (limited to 'src/command/StorageCommands.cxx')
-rw-r--r--src/command/StorageCommands.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/command/StorageCommands.cxx b/src/command/StorageCommands.cxx
index c77011cc0..87bb44199 100644
--- a/src/command/StorageCommands.cxx
+++ b/src/command/StorageCommands.cxx
@@ -24,6 +24,7 @@
#include "Request.hxx"
#include "CommandError.hxx"
#include "util/UriUtil.hxx"
+#include "util/ChronoUtil.hxx"
#include "util/ConstBuffer.hxx"
#include "fs/Traits.hxx"
#include "client/Client.hxx"
@@ -88,7 +89,7 @@ handle_listfiles_storage(Response &r, StorageDirectoryReader &reader)
break;
}
- if (info.mtime != 0)
+ if (!IsNegative(info.mtime))
time_print(r, "Last-Modified", info.mtime);
}
}