aboutsummaryrefslogtreecommitdiffstats
path: root/otr.c
diff options
context:
space:
mode:
authordequis <dx@dxzone.com.ar>2015-10-13 02:05:36 -0300
committerdequis <dx@dxzone.com.ar>2015-10-13 02:05:36 -0300
commit0b1ae595647712ecd9f69a74f210d58f570e74b9 (patch)
treea3e390b3412f6e3773189d707898224cb71d16b7 /otr.c
parent64bed24b810fa3c44d23132b2aa8792fc78ffe77 (diff)
otr: fix trailing whitespace issues with 'otr forget key'
Fixes trac ticket 1089, https://bugs.bitlbee.org/bitlbee/ticket/1089
Diffstat (limited to 'otr.c')
-rw-r--r--otr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/otr.c b/otr.c
index b45955d2..c17331a8 100644
--- a/otr.c
+++ b/otr.c
@@ -1735,6 +1735,9 @@ OtrlPrivKey *match_privkey(irc_t *irc, const char **args)
}
*p = '\0';
+ /* remove trailing whitespace */
+ g_strchomp(prefix);
+
/* find first key which matches the given prefix */
n = strlen(prefix);
for (k = irc->otr->us->privkey_root; k; k = k->next) {