openbsd-ports/net/bitchx/patches/patch-source_ctcp_c
2009-03-24 21:43:09 +00:00

15 lines
415 B
Plaintext

$OpenBSD: patch-source_ctcp_c,v 1.2 2009/03/24 21:43:09 naddy Exp $
--- source/ctcp.c.orig Mon Jan 8 07:24:22 2001
+++ source/ctcp.c Tue Mar 24 22:41:56 2009
@@ -1478,6 +1478,10 @@ extern void send_ctcp (int type, char *to, int datatag
*putbuf2;
int len;
len = IRCD_BUFFER_SIZE - (12 + strlen(to));
+
+ if (len < strlen(ctcp_cmd[datatag].name) + 3)
+ return;
+
putbuf2 = alloca(len);
if (format)