perf tools: Fix up /proc/PID/maps parsing
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 28 Oct 2013 12:38:12 +0000 (09:38 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 28 Oct 2013 12:38:12 +0000 (09:38 -0300)
commit2fd869f08aec5a8e4cbf01bc3fa345c4e53342d7
tree2ef5cef709986969a0f737331b4a1f1d725a92c8
parentc0268e8d1f450e286fc55e77f53a9ede6b72acab
perf tools: Fix up /proc/PID/maps parsing

When introducing support for MMAP2 we considered more parts of each map
representation in /proc/PID/maps, and when disabling it we forgot to
reduce the number of expected parsed/assigned entries in the sscanf
call, fix it to expect the right number of desired fields, 5.

Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Based-on-a-patch-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-vrbo1wik997ahjzl1chm3bdm@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/event.c