From 9a065829eb38d8f47482d353368c244a67729618 Mon Sep 17 00:00:00 2001 From: "pasko@chromium.org" Date: Wed, 12 Jun 2013 18:21:02 +0000 Subject: [PATCH] memreport.py: Strip EOL from memdump output This allows redirecting adb shell output directly to memreport.py without having to do dos2unix, and be able to match end of line in regexps. BUG=none Review URL: https://chromiumcodereview.appspot.com/16661004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@205875 0039d316-1c4b-4281-b951-d872f2087c98 --- tools/android/memdump/memreport.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/android/memdump/memreport.py b/tools/android/memdump/memreport.py index d0c6fceb7d11..62b3ac42ed34 100755 --- a/tools/android/memdump/memreport.py +++ b/tools/android/memdump/memreport.py @@ -47,7 +47,7 @@ def _CollectMemoryStats(memdump, region_filters): continue matched_regions = Set([]) for region_filter in region_filters: - if regexps[region_filter].match(line): + if regexps[region_filter].match(line.rstrip('\r\n')): matched_regions.add(region_filter) if not region_filter in mem_usage_for_regions: mem_usage_for_regions[region_filter] = { -- 2.11.4.GIT