mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-30 03:34:29 +03:00
Properly deal with classes destructors
There are some classes such as AuditLog that demands a reference count. That is needed because this class can be used by different instances of the Rules classes.
This commit is contained in:
@@ -45,6 +45,10 @@ ModSecurity::ModSecurity()
|
||||
}
|
||||
|
||||
|
||||
ModSecurity::~ModSecurity() {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @name whoAmI
|
||||
* @brief Return information about this ModSecurity version and platform.
|
||||
@@ -162,6 +166,18 @@ extern "C" const char *msc_who_am_i(ModSecurity *msc) {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @name msc_cleanup
|
||||
* @brief Cleanup ModSecurity C API
|
||||
*
|
||||
* Cleanup ModSecurity instance.
|
||||
*
|
||||
*/
|
||||
extern "C" void msc_cleanup(ModSecurity *msc) {
|
||||
delete msc;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @name msc_init
|
||||
* @brief Initilizes ModSecurity C API
|
||||
|
Reference in New Issue
Block a user