Fix repeated warning for file uploads limit exceeding

This commit is contained in:
Jakub Zelenka 2023-01-19 14:11:18 +00:00
parent f6808648a4
commit 830bdb582f
No known key found for this signature in database
GPG key ID: 1C0779DC5C0A9DE4

View file

@ -910,7 +910,10 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler) /* {{{ */
skip_upload = 1;
} else if (upload_cnt <= 0) {
skip_upload = 1;
sapi_module.sapi_error(E_WARNING, "Maximum number of allowable file uploads has been exceeded");
if (upload_cnt == 0) {
--upload_cnt;
sapi_module.sapi_error(E_WARNING, "Maximum number of allowable file uploads has been exceeded");
}
}
/* Return with an error if the posted data is garbled */