From 5aa1fbb66a02c2c8f41fc97aad434e4a38c9e2a0 Mon Sep 17 00:00:00 2001 From: edef Date: Sun, 31 Jul 2022 02:21:57 +0000 Subject: ripple/minitrace: recognise anonymous/special mappings by dev/inode Change-Id: If90d5e75e97bcac7c5d8bfa770c003a306f7ac7b --- ripple/minitrace/src/main.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ripple/minitrace/src/main.rs b/ripple/minitrace/src/main.rs index 3857b77..3675d08 100644 --- a/ripple/minitrace/src/main.rs +++ b/ripple/minitrace/src/main.rs @@ -150,11 +150,15 @@ impl Process { for &mut maps_file::Mapping { start, end, + dev, + inode, ref mut pathname, .. } in &mut mappings { - if pathname == "" || (pathname.starts_with('[') && pathname.ends_with(']')) { + if (dev, inode) == ((0, 0), 0) { + let is_special = pathname.starts_with('[') && pathname.ends_with(']'); + assert!(is_special || pathname.is_empty()); // these won't exist in map_files continue; } -- cgit 1.4.1