mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-18 06:53:20 +02:00
Provider better provider debug output and make fix killProcsByComm hanging on Xperia Z1.
This commit is contained in:
@@ -92,6 +92,10 @@ devutil.waitForPort = function(adb, serial, port) {
|
||||
}
|
||||
|
||||
devutil.listPidsByComm = function(adb, serial, comm, bin) {
|
||||
var users = {
|
||||
shell: true
|
||||
}
|
||||
|
||||
return adb.shellAsync(serial, ['ps', comm])
|
||||
.then(function(out) {
|
||||
return new Promise(function(resolve, reject) {
|
||||
@@ -104,7 +108,7 @@ devutil.listPidsByComm = function(adb, serial, comm, bin) {
|
||||
}
|
||||
else {
|
||||
var cols = chunk.toString().split(/\s+/)
|
||||
if (cols.pop() === bin) {
|
||||
if (cols.pop() === bin && users[cols[0]]) {
|
||||
pids.push(+cols[1])
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user