mirror of
https://github.com/github/codeql.git
synced 2026-04-27 17:55:19 +02:00
Revert "Go: Fix missing flow through receiver for function variable"
This commit is contained in:
@@ -90,7 +90,7 @@ predicate isWritableFileHandle(DataFlow::Node source, DataFlow::CallNode call) {
|
||||
/**
|
||||
* Holds if `os.File.Close` is called on `sink`.
|
||||
*/
|
||||
predicate isCloseSink(DataFlow::Node sink, DataFlow::MethodCallNode closeCall) {
|
||||
predicate isCloseSink(DataFlow::Node sink, DataFlow::CallNode closeCall) {
|
||||
// find calls to the os.File.Close function
|
||||
closeCall = any(CloseFileFun f).getACall() and
|
||||
// that are unhandled
|
||||
@@ -115,7 +115,7 @@ predicate isCloseSink(DataFlow::Node sink, DataFlow::MethodCallNode closeCall) {
|
||||
* Holds if `os.File.Sync` is called on `sink` and the result of the call is neither
|
||||
* deferred nor discarded.
|
||||
*/
|
||||
predicate isHandledSync(DataFlow::Node sink, DataFlow::MethodCallNode syncCall) {
|
||||
predicate isHandledSync(DataFlow::Node sink, DataFlow::CallNode syncCall) {
|
||||
// find a call of the `os.File.Sync` function
|
||||
syncCall = any(SyncFileFun f).getACall() and
|
||||
// match the sink with the object on which the method is called
|
||||
|
||||
Reference in New Issue
Block a user