summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-03-24 16:31:52 +0000
committerErik Johnston <erik@matrix.org>2015-03-24 16:31:52 +0000
commit0ba393924a823698eb5263a29ce6c4b50488ac4b (patch)
tree91e9987f30f5ee0a4449cf08e8c42f9d7f8312e4 /synapse/storage
parentDon't reinsert into event_edges (diff)
downloadsynapse-0ba393924a823698eb5263a29ce6c4b50488ac4b.tar.xz
Escape non printing ascii character
Diffstat (limited to '')
-rw-r--r--synapse/storage/room.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/storage/room.py b/synapse/storage/room.py
index 8641033327..501e947ad7 100644
--- a/synapse/storage/room.py
+++ b/synapse/storage/room.py
@@ -102,10 +102,10 @@ class RoomStore(SQLBaseStore):
                 "ON c.event_id = room_names.event_id "
             )
 
-            # We use non printing ascii character US () as a seperator
+            # We use non printing ascii character US (\x1F) as a separator
             sql = (
                 "SELECT r.room_id, n.name, t.topic, "
-                "group_concat(a.room_alias, '') "
+                "group_concat(a.room_alias, '\x1F') "
                 "FROM rooms AS r "
                 "LEFT JOIN (%(topic)s) AS t ON t.room_id = r.room_id "
                 "LEFT JOIN (%(name)s) AS n ON n.room_id = r.room_id "
@@ -130,7 +130,7 @@ class RoomStore(SQLBaseStore):
                 "room_id": r[0],
                 "name": r[1],
                 "topic": r[2],
-                "aliases": r[3].split(""),
+                "aliases": r[3].split("\x1F"),
             }
             for r in rows
         ]