Convert simple uses of alloca/strcpy to LOCAL_COPY.

git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@232 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
Tim Cava
2013-02-24 07:32:59 +00:00
parent a7c93a3950
commit d7a0c781f8
13 changed files with 19 additions and 38 deletions

View File

@@ -138,8 +138,7 @@ char *p = NULL;
char *pat;
if (!str || !*str || !get_int_var(AUTO_RESPONSE_VAR))
return 0;
p = alloca(strlen(auto_str)+1);
strcpy(p, auto_str);
p = LOCAL_COPY(auto_str);
if (p && *p)
{
while ((pat = next_arg(p, &p)))
@@ -1090,8 +1089,7 @@ static void p_channel(char *from, char **ArgList)
#ifdef WANT_NSLOOKUP
char *host;
#endif
user = alloca(strlen(FromUserHost)+1);
strcpy(user, FromUserHost);
user = LOCAL_COPY(FromUserHost);
#ifdef WANT_NSLOOKUP
if ((host = strchr(user, '@')))