diff options
author | Sven Moritz Hallberg <pesco@khjk.org> | 2009-03-13 12:31:47 +0100 |
---|---|---|
committer | Sven Moritz Hallberg <pesco@khjk.org> | 2009-03-13 12:31:47 +0100 |
commit | fc34fb5d0b717d90edfc7ed78f11166eb23c536e (patch) | |
tree | efe1cf653c46544a74dc0bf430ce3125769002cd /otr.c | |
parent | 673a54c5a78afd1dd41b4cd8811df5ab65042583 (diff) |
dont specify a background when coloring encrypted messages
Diffstat (limited to 'otr.c')
-rw-r--r-- | otr.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -349,7 +349,14 @@ char *otr_handle_message(struct im_connection *ic, const char *handle, const cha color=3; /* green */ else color=5; /* red */ - colormsg = g_strdup_printf("\x03%.2d,00%s\x0F", color, newmsg); + + if(newmsg[0] == ',') { + /* could be a problem with the color code */ + /* insert a space between color spec and message */ + colormsg = g_strdup_printf("\x03%.2d %s\x0F", color, newmsg); + } else { + colormsg = g_strdup_printf("\x03%.2d%s\x0F", color, newmsg); + } } else { colormsg = g_strdup(newmsg); } |