From 395674dd9431847aecf33be72c232b2405a4716a Mon Sep 17 00:00:00 2001 From: david Date: Sat, 27 Feb 2021 15:54:50 +0000 Subject: [PATCH] made sure the wait for application finish happened before the output was written --- CHANGELOG.md | 3 +++ jnitrace/jnitrace.py | 4 ++-- package.json | 2 +- setup.py | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0dfaeda..22a0e8a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # jnitrace Change Log +## 3.2.1 +- Fixed bug where output was being written before the tracing was complete + ## 3.2.0 - Added support for connecting to a remote Frida server diff --git a/jnitrace/jnitrace.py b/jnitrace/jnitrace.py index ce912ae..a9072d9 100644 --- a/jnitrace/jnitrace.py +++ b/jnitrace/jnitrace.py @@ -623,12 +623,12 @@ def main(): if args.inject_method == "spawn": device.resume(pid) + _wait_for_finish() + if args.output: json.dump(formatter.get_output(), args.output, indent=4) args.output.close() - _wait_for_finish() - _finish(args, device, pid, scripts) if __name__ == '__main__': diff --git a/package.json b/package.json index 5648ebf..92f375c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jnitrace", - "version": "3.2.0", + "version": "3.2.1", "description": "A tool for tracing use of the JNI in Android apps", "private": true, "main": "jnitrace/src/main.js", diff --git a/setup.py b/setup.py index 92770a3..3ab1e5c 100644 --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ setup( name='jnitrace', - version='3.2.0', + version='3.2.1', description='A tool for tracing use of the JNI in Android apps', long_description=long_description, long_description_content_type='text/markdown',