Skip to content

Commit 6c3c4c3

Browse files
MathiasVPgeoffw0
andauthored
Update cpp/ql/lib/semmle/code/cpp/security/InvalidPointerDereference/InvalidPointerToDereference.qll
Co-authored-by: Geoffrey White <40627776+geoffw0@users.noreply.github.com>
1 parent 4075dac commit 6c3c4c3

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

cpp/ql/lib/semmle/code/cpp/security/InvalidPointerDereference/InvalidPointerToDereference.qll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
*
66
* Consider the following snippet:
77
* ```cpp
8-
* 1. char* begin = (char*)malloc(size);
9-
* 2. char* end = begin + size;
10-
* 3. for(int *p = begin; p <= end; p++) {
8+
* 1. char* base = (char*)malloc(size);
9+
* 2. char* end = base + size;
10+
* 3. for(int *p = base; p <= end; p++) {
1111
* 4. use(*p);
1212
* 5. }
1313
* ```

0 commit comments

Comments
 (0)