Commit e3e7a598 authored by owenlin@chromium.org's avatar owenlin@chromium.org

Fix browser.memory_stats has no GPU and Renderer info on CrOS

BUG=284219
TEST=run related code on daisy
NOTRY=true

Review URL: https://chromiumcodereview.appspot.com/23745007

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@221637 0039d316-1c4b-4281-b951-d872f2087c98
parent 5252d391
...@@ -56,14 +56,13 @@ class CrosPlatformBackend(platform_backend.PlatformBackend): ...@@ -56,14 +56,13 @@ class CrosPlatformBackend(platform_backend.PlatformBackend):
def GetChildPids(self, pid): def GetChildPids(self, pid):
"""Returns a list of child pids of |pid|.""" """Returns a list of child pids of |pid|."""
all_process_info = self._cri.ListProcesses() all_process_info = self._cri.ListProcesses()
processes = [] processes = [(curr_pid, curr_ppid, curr_state)
for pid, _, ppid, state in all_process_info: for curr_pid, _, curr_ppid, curr_state in all_process_info]
processes.append((pid, ppid, state))
return proc_util.GetChildPids(processes, pid) return proc_util.GetChildPids(processes, pid)
def GetCommandLine(self, pid): def GetCommandLine(self, pid):
command = self._GetPsOutput(['command'], pid) command = self._GetFileContents('/proc/%s/cmdline' % pid)
return command[0] if command else None return command if command else None
def CanFlushIndividualFilesFromSystemCache(self): def CanFlushIndividualFilesFromSystemCache(self):
return True return True
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment