mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
17 lines
163 B
C++
17 lines
163 B
C++
void g() {
|
|
MyTask *task = nullptr;
|
|
|
|
try
|
|
{
|
|
task = new MyTask;
|
|
|
|
...
|
|
|
|
delete task;
|
|
|
|
...
|
|
} catch (...) {
|
|
delete task; // BAD: potential double-free
|
|
}
|
|
}
|