trying to invoke the script after selecting APK it throws NPE
Cannot invoke "ghidra.program.model.listing.Program.getListing()" because "this.currentProgram" is null
java.lang.NullPointerException: Cannot invoke "ghidra.program.model.listing.Program.getListing()" because "this.currentProgram" is null
at ghidra.program.flatapi.FlatProgramAPI.getFirstFunction(FlatProgramAPI.java:1155)
at JNIAnalyzer.run(JNIAnalyzer.java:49)
at ghidra.app.script.GhidraScript.executeNormal(GhidraScript.java:395)
at ghidra.app.script.GhidraScript.doExecute(GhidraScript.java:250)
at ghidra.app.script.GhidraScript.execute(GhidraScript.java:228)
at ghidra.app.plugin.core.script.RunScriptTask.run(RunScriptTask.java:47)
at ghidra.util.task.Task.monitoredRun(Task.java:134)
at ghidra.util.task.TaskRunner.lambda$startTaskThread$0(TaskRunner.java:106)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:833)
Build Date: 2023-Feb-08 1242 EST
Ghidra Version: 10.2.3
Java Home: /usr/lib/jvm/java-17-openjdk-amd64
JVM Version: Private Build 17.0.5
OS: Linux 5.15.0-60-generic amd64
trying to invoke the script after selecting APK it throws NPE
Cannot invoke "ghidra.program.model.listing.Program.getListing()" because "this.currentProgram" is null java.lang.NullPointerException: Cannot invoke "ghidra.program.model.listing.Program.getListing()" because "this.currentProgram" is null at ghidra.program.flatapi.FlatProgramAPI.getFirstFunction(FlatProgramAPI.java:1155) at JNIAnalyzer.run(JNIAnalyzer.java:49) at ghidra.app.script.GhidraScript.executeNormal(GhidraScript.java:395) at ghidra.app.script.GhidraScript.doExecute(GhidraScript.java:250) at ghidra.app.script.GhidraScript.execute(GhidraScript.java:228) at ghidra.app.plugin.core.script.RunScriptTask.run(RunScriptTask.java:47) at ghidra.util.task.Task.monitoredRun(Task.java:134) at ghidra.util.task.TaskRunner.lambda$startTaskThread$0(TaskRunner.java:106) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) at java.base/java.lang.Thread.run(Thread.java:833)
Build Date: 2023-Feb-08 1242 EST Ghidra Version: 10.2.3 Java Home: /usr/lib/jvm/java-17-openjdk-amd64 JVM Version: Private Build 17.0.5 OS: Linux 5.15.0-60-generic amd64