From a2ad0ba630da3552b3c2d3d2f09db0a43e4fcc9d Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Fri, 1 Aug 2014 10:53:33 +0300 Subject: Android: Fix debugging. When re-install a package without uninstalling it first, a few files are leftover from the previous installation which makes the debugging to fail. Change-Id: I603491668bcec2a6f8054951ea2dea806fcc4c88 Reviewed-by: hjk Reviewed-by: Eskil Abrahamsen Blomfeldt --- .../jar/src/org/qtproject/qt5/android/QtActivityDelegate.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/android') diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java b/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java index 79e30f0552..9407db932f 100644 --- a/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java +++ b/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java @@ -542,6 +542,11 @@ public class QtActivityDelegate int timeOut = 30000; // ms until we give up on ping and pong int maxAttempts = timeOut / napTime; + if (gdbserverSocket != null) { + debugLog("removing gdb socket " + gdbserverSocket); + new File(gdbserverSocket).delete(); + } + if (usePing) { debugLog("removing ping file " + pingFile); File ping = new File(pingFile); @@ -616,6 +621,8 @@ public class QtActivityDelegate debugLog("go to sleep"); Thread.sleep(napTime); } + debugLog("Removing pingFile " + pingFile); + new File(pingFile).delete(); if (i == maxAttempts) { debugLog("time out when waiting for pong file"); -- cgit v1.2.3