aboutsummaryrefslogtreecommitdiffstats
path: root/main/weechat/CVE-2017-8073.patch
blob: 0b6baf9463d84e48cde8ce0853e7c5077986e076 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
From 2fb346f25f79e412cf0ed314fdf791763c19b70b Mon Sep 17 00:00:00 2001
From: Tobias Stoeckmann <tobias@stoeckmann.org>
Date: Sat, 22 Apr 2017 15:10:53 +0200
Subject: [PATCH] irc: fix parsing of DCC filename

---
 src/plugins/irc/irc-ctcp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/plugins/irc/irc-ctcp.c b/src/plugins/irc/irc-ctcp.c
index e62832b..8afee68 100644
--- a/src/plugins/irc/irc-ctcp.c
+++ b/src/plugins/irc/irc-ctcp.c
@@ -512,7 +512,7 @@ irc_ctcp_dcc_filename_without_quotes (const char *filename)
     int length;
 
     length = strlen (filename);
-    if (length > 0)
+    if (length > 1)
     {
         if ((filename[0] == '\"') && (filename[length - 1] == '\"'))
             return weechat_strndup (filename + 1, length - 2);