Skip to content

Query evaluation ran out of memory (Java heap maximum: 1165 MiB, Off-heap arrays maximum: 1941 MiB). #865

Open
@raj-kumar-j

Description

@raj-kumar-j

Hi Team, I'm using vscode-codeql version 1.4.8 and I got this error Query evaluation ran out of memory (Java heap maximum: 1165 MiB, Off-heap arrays maximum: 1941 MiB). while running a query to find UAF vulnerability in C source code. The db size is 4+ gb. The query execution stopped after this error. Below is the query I executed.

import cpp
import semmle.code.cpp.dataflow.DataFlow
import DataFlow::PathGraph

class Config extends DataFlow::Configuration{
    Config() {this = "Use after free"}

    override predicate isSource(DataFlow::Node arg) {
        exists(FunctionCall call |
            call.getArgument(0) = arg.asDefiningArgument() /* for pointers use asDefiningArgument */  and
            call.getTarget().hasGlobalOrStdName("free")
        )
    }
    
    override predicate isSink(DataFlow::Node sink) {
        dereferenced(sink.asExpr())
    }
}

from DataFlow::PathNode source, DataFlow::PathNode sink, Config config
where config.hasFlowPath(source, sink)
select sink, source, sink, "Potential Use After Free"

I was searching ways to increase heap size but I do not have java installed on my windows 10.

Metadata

Metadata

Assignees

No one assigned

    Labels

    VSCodequestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions