diff options
author | Gary Kramlich <grim@reaperworld.com> | 2018-03-06 06:24:07 +0000 |
---|---|---|
committer | Gary Kramlich <grim@reaperworld.com> | 2018-03-06 06:24:07 +0000 |
commit | 98a84863f95a6f763bfa98ab144451d8f683d6fd (patch) | |
tree | 2c6587a00e367d4eb490ff723a5a084ae299b1df | |
parent | 222769ce99ca3b940fc6d41d3d2c70d5e50e872a (diff) | |
parent | a51cac374ab8129db74654af2c7ce0435a1aaf30 (diff) | |
download | pidgin-98a84863f95a6f763bfa98ab144451d8f683d6fd.tar.gz |
Merged in dequisdequis/security/release-2.x.y (pull request #23)
irc: Fix write of a single \0 before the start of a buffer in irc_parse_ctcp
Approved-by: Gary Kramlich <grim@reaperworld.com>
-rw-r--r-- | libpurple/protocols/irc/parse.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libpurple/protocols/irc/parse.c b/libpurple/protocols/irc/parse.c index f1478c8b53..c59824fbc7 100644 --- a/libpurple/protocols/irc/parse.c +++ b/libpurple/protocols/irc/parse.c @@ -555,7 +555,7 @@ char *irc_parse_ctcp(struct irc_conn *irc, const char *from, const char *to, con * message and low-level quoting ... but if you want that crap, * use a real IRC client. */ - if (msg[0] != '\001' || msg[strlen(msg) - 1] != '\001') + if (msg[0] != '\001' || msg[1] == '\0' || msg[strlen(msg) - 1] != '\001') return g_strdup(msg); if (!strncmp(cur, "ACTION ", 7)) { |