From 5860f6fcbfab4d88868b67d75b1c864cfb90ba02 Mon Sep 17 00:00:00 2001 From: Emma Broman Date: Wed, 23 Sep 2020 10:43:37 +0200 Subject: [PATCH] Fix problem with extra symbol when returning string_view from format conversion --- src/util/time.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/time.cpp b/src/util/time.cpp index 203abb7778..e0be6096eb 100644 --- a/src/util/time.cpp +++ b/src/util/time.cpp @@ -108,8 +108,8 @@ std::string_view Time::ISO8601() const { std::memset(b, 0, S); SpiceManager::ref().dateFromEphemerisTime(_time, b, S, Format); - - return std::string_view(b, S); + + return std::string_view(b, S-1); } void Time::ISO8601(char* buffer) const {