From: wessels <> Date: Mon, 15 Apr 1996 09:58:32 +0000 (+0000) Subject: make code an array; SunOS segv'd X-Git-Tag: SQUID_3_0_PRE1~6181 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=463ff95e367b729566e5b216ed903b0560b12877;p=thirdparty%2Fsquid.git make code an array; SunOS segv'd --- diff --git a/src/url.cc b/src/url.cc index 41e591eb75..98de550567 100644 --- a/src/url.cc +++ b/src/url.cc @@ -1,4 +1,4 @@ -/* $Id: url.cc,v 1.12 1996/04/12 04:53:53 wessels Exp $ */ +/* $Id: url.cc,v 1.13 1996/04/15 03:58:32 wessels Exp $ */ /* * DEBUG: Section 23 url @@ -18,7 +18,7 @@ char *url_convert_hex(org_url, allocate) char *org_url; int allocate; { - static char *code = "00"; + static char code[] = "00"; char *url = NULL; char *s = NULL; char *t = NULL; @@ -30,8 +30,8 @@ char *url_convert_hex(org_url, allocate) for (s = t = url; *(s + 2); s++) { if (*s == '%') { - *code = *++s; - *(code + 1) = *++s; + code[0] = *(++s); + code[1] = *(++s); *t++ = (char) strtol(code, NULL, 16); } else { *t++ = *s;