From d891a31c90b6b5f82a97de96a401b3165b7e9f58 Mon Sep 17 00:00:00 2001 From: baldurk Date: Thu, 4 May 2023 19:44:25 +0100 Subject: [PATCH] Make android timeouts even more ludicrously generous --- renderdoc/android/android.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/renderdoc/android/android.cpp b/renderdoc/android/android.cpp index b7e53db53..f3ee3b23a 100644 --- a/renderdoc/android/android.cpp +++ b/renderdoc/android/android.cpp @@ -181,8 +181,9 @@ int GetCurrentPID(const rdcstr &deviceID, const rdcstr &processName) RDCLOG("Getting PID from device %s for process '%s'", deviceID.c_str(), processName.c_str()); } - // try 5 times, 200ms apart to find the pid - for(int i = 0; i < 5; i++) + // try 15 times, 200ms apart to find the pid, for a total of 3 seconds timeout waiting for the + // process to even be alive + for(int i = 0; i < 15; i++) { Process::ProcessResult pidOutput = adbExecCommand(deviceID, StringFormat::Fmt("shell ps -A | grep %s", processName.c_str())); @@ -1094,7 +1095,7 @@ struct AndroidController : public IDeviceProtocolHandler }); // allow the package to start and begin listening before we return - Threading::Sleep(5000); + Threading::Sleep(8000); return result; }