diff options
author | Sven Moritz Hallberg <sm@khjk.org> | 2008-02-18 10:36:23 +0100 |
---|---|---|
committer | Sven Moritz Hallberg <sm@khjk.org> | 2008-02-18 10:36:23 +0100 |
commit | 5933da72f1f04810a1b789f9e1e1c1d7e360f30f (patch) | |
tree | 972445febe0df5811eff8499dabee0a37cb1d7a1 | |
parent | fcfd9c56a81a993d86f18c792b1584ec5c5dca99 (diff) |
fix "purple message" bug ;)
-rw-r--r-- | otr.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -337,13 +337,13 @@ char *otr_handle_message(struct im_connection *ic, const char *handle, const cha if(context && context->msgstate == OTRL_MSGSTATE_ENCRYPTED && set_getbool(&ic->irc->set, "color_encrypted")) { /* color according to f'print trust */ - char color; + int color; const char *trust = context->active_fingerprint->trust; if(trust && trust[0] != '\0') - color='3'; /* green */ + color=3; /* green */ else - color='5'; /* red */ - colormsg = g_strdup_printf("\x03%c%s\x0F", color, newmsg); + color=5; /* red */ + colormsg = g_strdup_printf("\x03%.2d%s\x0F", color, newmsg); } else { colormsg = g_strdup(newmsg); } |