mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
17 lines
318 B
Plaintext
17 lines
318 B
Plaintext
/**
|
|
* @name If statements with empty then branch
|
|
* @description Finds 'if' statements where the 'then' branch is
|
|
* an empty block statement
|
|
* @tags if
|
|
* then
|
|
* empty
|
|
* conditional
|
|
* branch
|
|
*/
|
|
|
|
import java
|
|
|
|
from IfStmt i
|
|
where i.getThen().(Block).getNumStmt() = 0
|
|
select i
|