Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0a85637

Browse files
committed
CPP: Add a test.
1 parent 9b9d712 commit 0a85637

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

cpp/ql/test/query-tests/jsf/4.13 Functions/AV Rule 114/AV Rule 114.expected

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
| test.c:8:5:8:14 | declaration | Function f2 should return a value of type int but does not return a value here |
44
| test.c:25:9:25:14 | ExprStmt | Function f4 should return a value of type int but does not return a value here |
55
| test.c:39:9:39:14 | ExprStmt | Function f6 should return a value of type int but does not return a value here |
6+
| test.c:100:2:100:18 | asm statement | Function f14 should return a value of type int but does not return a value here |
67
| test.cpp:16:1:18:1 | { ... } | Function g2 should return a value of type MyValue but does not return a value here |
78
| test.cpp:48:2:48:26 | if (...) ... | Function g7 should return a value of type MyValue but does not return a value here |
89
| test.cpp:74:1:76:1 | { ... } | Function g10 should return a value of type second but does not return a value here |

cpp/ql/test/query-tests/jsf/4.13 Functions/AV Rule 114/test.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,3 +94,8 @@ void f13_func(int x)
9494
{
9595
if (x < 10) return; // GOOD
9696
}
97+
98+
int f14()
99+
{
100+
__asm__("rdtsc"); // GOOD [FALSE POSITIVE]
101+
}

0 commit comments

Comments
 (0)