summaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
Diffstat (limited to 'server')
-rw-r--r--server/src/macrotool/export.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/server/src/macrotool/export.cc b/server/src/macrotool/export.cc
index 150a85c..c9dcbd1 100644
--- a/server/src/macrotool/export.cc
+++ b/server/src/macrotool/export.cc
@@ -217,7 +217,10 @@ static void export_prefix(std::string prefix)
files[templ]->addcell("patientid", patientid);
files[templ]->addcell("template", templ);
time_t t = atol(timestamp.c_str());
- files[templ]->addcell("time", ctime(&t));
+ std::string timestr = ctime(&t);
+ if(timestr[timestr.size() - 1] == '\n')
+ timestr = timestr.substr(0, timestr.size() - 1);
+ files[templ]->addcell("time", timestr.c_str());
printf("%s %s %s\n", timestamp.c_str(), patientid.c_str(), templ.c_str());