cvs: php4 /main SAPI.c

From: Date: Sun, 27 Aug 2000 09:32:23 +0000
Subject: cvs: php4 /main SAPI.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-1404@lists.php.net to get a copy of this message
sas Sun Aug 27 02:32:23 2000 EDT Modified files: /php4/main SAPI.c Log: newtype has a length of newlen+1, 'len' refers to the length of *mimetype here. Index: php4/main/SAPI.c diff -u php4/main/SAPI.c:1.83 php4/main/SAPI.c:1.84 --- php4/main/SAPI.c:1.83 Sun Aug 20 07:20:21 2000 +++ php4/main/SAPI.c Sun Aug 27 02:32:23 2000 @@ -247,8 +247,8 @@ if (*charset && strncmp(*mimetype, "text/", 5) == 0 && strstr(*mimetype, "charset=") == NULL) { newlen = len + (sizeof(";charset=")-1) + strlen(charset); newtype = emalloc(newlen + 1); - strlcpy(newtype, *mimetype, len); - strlcat(newtype, ";charset=", len); + PHP_STRLCPY(newtype, *mimetype, newlen + 1, len); + strlcat(newtype, ";charset=", newlen + 1); if (*mimetype != NULL) { efree(*mimetype); }

« previous php.cvs (#1404) next »