summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2011-11-25 09:28:31 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2011-11-25 09:28:31 +0100
commitc41c204f421c4c1bc453932d2d5552227d794201 (patch)
tree7a75da26fc8a6ccb16b9e23619535505d7727fa7
parent07244d0376e2e25eaeba913e684bd06122ded893 (diff)
Replace newline with symbol to avoid new row generation in office import.
-rw-r--r--server/src/admin_export.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/server/src/admin_export.cc b/server/src/admin_export.cc
index 3ec77d1..e125699 100644
--- a/server/src/admin_export.cc
+++ b/server/src/admin_export.cc
@@ -47,8 +47,10 @@ static std::string escape(std::string &str)
std::string::iterator i = str.begin();
while(i != str.end()) {
if(*i == '\"') out += "''";
+ else if(*i == '\n') out += "\342\220\244"; // N/L controlcharacter pictogram
+ else if(*i == '\r') { }
else out += *i;
- i++;
+ i++;
}
out += "\"";
return out;