mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-29 11:16:33 +03:00
Added methods to free buffers allocated by ModSecurity APIs
- The following methods are introduced to allow clients of libModSecurity that are not able to link and call the C/C++ standard library to be able to free the buffers allocated by libModSecurity. - msc_intervention_cleanup: Frees the buffers in a ModSecurityIntervention structure that have been allocated by calls to msc_intervention. - msc_rules_error_cleanup: Frees an error message buffer allocated by the msc_rules_xxx functions to detail the condition that triggered the error.
This commit is contained in:
@@ -68,6 +68,8 @@ int main (int argc, char **argv)
|
||||
msc_process_response_body(transaction);
|
||||
msc_process_logging(transaction);
|
||||
end:
|
||||
if(error != NULL)
|
||||
msc_rules_error_cleanup(error);
|
||||
msc_rules_cleanup(rules);
|
||||
msc_cleanup(modsec);
|
||||
|
||||
|
Reference in New Issue
Block a user