summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfoobar <sniper@php.net>2002-04-23 00:14:08 +0000
committerfoobar <sniper@php.net>2002-04-23 00:14:08 +0000
commitae2e36a4e5a74fbcd3f58d2ea3b9371a3cf0410e (patch)
tree8cfacc06a0a4ad95df505c0285cbbc04577f8ee4
parent36e51815ad8ce90c69a3a55ddca79fb40304a467 (diff)
downloadphp-git-ae2e36a4e5a74fbcd3f58d2ea3b9371a3cf0410e.tar.gz
Changed the error for 'no upload' to E_NOTICE so that it doesn't
pollute the logs too much. @- Fixed possible crash bug in HTTP uploads. (Patch: Lucas Schroeder)
-rw-r--r--main/rfc1867.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/main/rfc1867.c b/main/rfc1867.c
index 5c997cda6a..84c6078e38 100644
--- a/main/rfc1867.c
+++ b/main/rfc1867.c
@@ -371,11 +371,12 @@ static char *php_mime_get_hdr_value(zend_llist header, char *key)
}
entry = zend_llist_get_first(&header);
- do {
+ while (entry) {
if (!strcasecmp(entry->key, key)) {
return entry->value;
}
- } while ((entry = zend_llist_get_next(&header)));
+ entry = zend_llist_get_next(&header);
+ }
return NULL;
}
@@ -726,7 +727,7 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler)
cancel_upload = 0;
if(strlen(filename) == 0) {
- sapi_module.sapi_error(E_WARNING, "No file uploaded");
+ sapi_module.sapi_error(E_NOTICE, "No file uploaded");
cancel_upload = UPLOAD_ERROR_D;
}