mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-16 09:31:53 +03:00
json parser handle cleanup
This commit is contained in:
committed by
Felipe Zimmerle
parent
923c3c6793
commit
21a63cb83e
@@ -306,10 +306,14 @@ int json_complete(modsec_rec *msr, char **error_msg) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Frees the resources used for XML parsing.
|
* Frees the resources used for JSON parsing.
|
||||||
*/
|
*/
|
||||||
apr_status_t json_cleanup(modsec_rec *msr) {
|
apr_status_t json_cleanup(modsec_rec *msr) {
|
||||||
msr_log(msr, 4, "JSON: Cleaning up JSON results");
|
msr_log(msr, 4, "JSON: Cleaning up JSON results");
|
||||||
|
if (msr->json->handle != NULL) {
|
||||||
|
yajl_free(msr->json->handle);
|
||||||
|
msr->json->handle = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user