From b1d55bce829cbe7b9acf92655998c8af80aada05 Mon Sep 17 00:00:00 2001 From: Tim Cava Date: Wed, 14 Aug 2013 04:15:09 +0000 Subject: [PATCH] Use memcpy, rather than strmcpy or strlcpy, in parse_command(). Suggested by caf. git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@316 13b04d17-f746-0410-82c6-800466cd88b0 --- source/commands.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/commands.c b/source/commands.c index 165683d..b032f57 100644 --- a/source/commands.c +++ b/source/commands.c @@ -4637,7 +4637,8 @@ static unsigned int level = 0; if ((rest = strchr(line, ' '))) { cline = alloca((rest - line) + 1); - strmcpy(cline, line, (rest - line)); + memcpy(cline, line, rest - line); + cline[rest - line] = 0; rest++; } else