Files
codeql/java/ql/test/query-tests/security/CWE-676/semmle/tests/Test.java
2018-08-30 10:48:05 +01:00

17 lines
356 B
Java

// Semmle test case for CWE-676: Use of Potentially Dangerous Function
// http://cwe.mitre.org/data/definitions/676.html
package test.cwe676.semmle.tests;
class Test {
private Thread worker;
public Test(Thread worker) {
this.worker = worker;
}
public void quit() {
// Stop
worker.stop(); // BAD: Thread.stop can result in corrupted data
}
}