Use ps -A when looking for PID of injected process.

This commit is contained in:
michaelrgb
2018-03-01 17:17:24 +00:00
committed by Baldur Karlsson
parent b7c69bd823
commit 327da91706
+1 -1
View File
@@ -95,7 +95,7 @@ int GetCurrentPID(const std::string &deviceID, const std::string &packageName)
for(int i = 0; i < 5; i++)
{
Process::ProcessResult pidOutput =
adbExecCommand(deviceID, StringFormat::Fmt("shell ps | grep %s", packageName.c_str()));
adbExecCommand(deviceID, StringFormat::Fmt("shell ps -A | grep %s", packageName.c_str()));
std::string output = trim(pidOutput.strStdout);
size_t space = output.find_first_of("\t ");