Files
codeql/csharp/ql/examples/throw_exception.ql
2019-07-26 17:47:11 +02:00

13 lines
319 B
Plaintext

/**
* @name Throw exception of given type
* @description Finds places where we throw 'System.IO.IOException' or one of its subtypes.
* @tags throw
* exception
*/
import csharp
from ThrowStmt throw
where throw.getThrownExceptionType().getBaseClass*().hasQualifiedName("System.IO.IOException")
select throw