mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-29 19:24:29 +03:00
Avoids memory leak by cleaning loc stack on Driver's destructor
This commit is contained in:
committed by
Felipe Zimmerle
parent
8edffe353c
commit
1aa2a9c01b
@@ -33,7 +33,11 @@ Driver::Driver()
|
||||
|
||||
|
||||
Driver::~Driver() {
|
||||
delete loc.back();
|
||||
while (loc.empty() == false) {
|
||||
yy::location *a = loc.back();
|
||||
loc.pop_back();
|
||||
delete a;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user