mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-30 11:44:32 +03:00
Fixed error detection for operator init.
This commit is contained in:
@@ -229,7 +229,7 @@ static int test_op(const char *name, const char *param, const unsigned char *inp
|
|||||||
/* Initialize the operator parameter */
|
/* Initialize the operator parameter */
|
||||||
if (metadata->param_init != NULL) {
|
if (metadata->param_init != NULL) {
|
||||||
rc = metadata->param_init(rule, errmsg);
|
rc = metadata->param_init(rule, errmsg);
|
||||||
if (rc < 0) {
|
if (rc <= 0) {
|
||||||
*errmsg = apr_psprintf(g_mp, "Failed to init op \"%s\": %s", name, *errmsg);
|
*errmsg = apr_psprintf(g_mp, "Failed to init op \"%s\": %s", name, *errmsg);
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user