CVS update: php3

From: Date: Sat, 26 Dec 1998 16:56:15 +0000
Subject: CVS update: php3
Groups: php.dev 
Request: Send a blank email to php-dev+get-3050@lists.php.net to get a copy of this message
Date: Saturday December 26, 1998 @ 11:56 Author: zeev Update of /repository/php3 In directory asf:/u/temp/cvs-serv14351 Modified Files: main.c Log Message: Unless I'm missing something, this duplication is entirely unnecessary (unchecked, I don't have apache around to test it on) Index: php3/main.c diff -c php3/main.c:1.483 php3/main.c:1.484 *** php3/main.c:1.483 Sun Dec 20 15:08:27 1998 --- php3/main.c Sat Dec 26 11:56:14 1998 *************** *** 29,35 **** +----------------------------------------------------------------------+ */ ! /* $Id: main.c,v 1.483 1998/12/20 20:08:27 shane Exp $ */ /* #define CRASH_DETECTION */ --- 29,35 ---- +----------------------------------------------------------------------+ */ ! /* $Id: main.c,v 1.484 1998/12/26 16:56:14 zeev Exp $ */ /* #define CRASH_DETECTION */ *************** *** 1295,1305 **** register int i; array_header *arr = table_elts(GLOBAL(php3_rqst)->subprocess_env); table_entry *elts = (table_entry *) arr->elts; - int len; for (i = 0; i < arr->nelts; i++) { len = strlen(elts[i].key); ! t = estrndup(elts[i].key, len); if (elts[i].val) { tmp.value.str.len = strlen(elts[i].val); tmp.value.str.val = estrndup(elts[i].val, tmp.value.str.len); --- 1295,1304 ---- register int i; array_header *arr = table_elts(GLOBAL(php3_rqst)->subprocess_env); table_entry *elts = (table_entry *) arr->elts; for (i = 0; i < arr->nelts; i++) { len = strlen(elts[i].key); ! t = elts[i].key; if (elts[i].val) { tmp.value.str.len = strlen(elts[i].val); tmp.value.str.val = estrndup(elts[i].val, tmp.value.str.len); *************** *** 1308,1317 **** tmp.value.str.val = empty_string; } tmp.type = IS_STRING; ! if (_php3_hash_update(&GLOBAL(symbol_table), t, len + 1, &tmp, sizeof(pval), NULL) == FAILURE) { STR_FREE(tmp.value.str.val); } - efree(t); } /* insert special variables */ if (_php3_hash_find(&GLOBAL(symbol_table), "SCRIPT_FILENAME", sizeof("SCRIPT_FILENAME"), (void **) & tmp_ptr) == SUCCESS) { --- 1307,1315 ---- tmp.value.str.val = empty_string; } tmp.type = IS_STRING; ! if (_php3_hash_update(&GLOBAL(symbol_table), t, strlen(t)+1, &tmp, sizeof(pval), NULL) == FAILURE) { STR_FREE(tmp.value.str.val); } } /* insert special variables */ if (_php3_hash_find(&GLOBAL(symbol_table), "SCRIPT_FILENAME", sizeof("SCRIPT_FILENAME"), (void **) & tmp_ptr) == SUCCESS) { -- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net For help: php-dev-help@lists.php.net

« previous php.dev (#3050) next »