3rd time's a charm

This commit is contained in:
Zeev Suraski 2000-09-04 20:47:52 +00:00
parent 4396093666
commit 388170ffa5

View File

@ -202,10 +202,8 @@ static void php_mime_split(char *buf, int cnt, char *boundary, zval *array_ptr)
}
abuf = estrndup(namebuf, strlen(namebuf)-arr_len);
sprintf(lbuf, "%s_name[%s]", abuf, arr_index);
add_protected_variable(lbuf PLS_CC);
} else {
sprintf(lbuf, "%s_name", namebuf);
add_protected_variable(lbuf PLS_CC);
}
s = strrchr(filenamebuf, '\\');
if (s && s > filenamebuf) {
@ -213,6 +211,7 @@ static void php_mime_split(char *buf, int cnt, char *boundary, zval *array_ptr)
} else {
safe_php_register_variable(lbuf, filenamebuf, NULL ELS_CC PLS_CC);
}
add_protected_variable(lbuf PLS_CC);
/* Add $foo[name] */
if (is_arr_upload) {