mirror of
https://github.com/github/codeql.git
synced 2026-04-25 08:45:14 +02:00
CPP: Tidy and simplify AV Rule 79.ql.
This commit is contained in:
@@ -16,3 +16,4 @@
|
||||
| Variants.cpp:25:3:25:13 | ... = ... | Resource f is acquired by class MyClass4 but not released anywhere in this class. |
|
||||
| Variants.cpp:65:3:65:17 | ... = ... | Resource a is acquired by class MyClass6 but not released anywhere in this class. |
|
||||
| Variants.cpp:66:3:66:36 | ... = ... | Resource b is acquired by class MyClass6 but not released anywhere in this class. |
|
||||
| Variants.cpp:67:3:67:41 | ... = ... | Resource c is acquired by class MyClass6 but not released anywhere in this class. |
|
||||
|
||||
@@ -64,7 +64,7 @@ public:
|
||||
{
|
||||
a = new int[10]; // BAD
|
||||
b = (int *)calloc(10, sizeof(int)); // BAD
|
||||
c = (int *)realloc(0, 10 * sizeof(int)); // BAD [NOT DETECTED]
|
||||
c = (int *)realloc(0, 10 * sizeof(int)); // BAD
|
||||
}
|
||||
|
||||
~MyClass6()
|
||||
|
||||
Reference in New Issue
Block a user