Skip to content

Commit 8e49601

Browse files
[3.14] gh-142627: Ignore anonymous mappings in Linux remote debugging (GH-142628) (#142630)
gh-142627: Ignore anonymous mappings in Linux remote debugging (GH-142628) (cherry picked from commit e0bca09) Co-authored-by: Victor Stinner <[email protected]>
1 parent c3fbe28 commit 8e49601

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Python/remote_debug.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -720,6 +720,11 @@ search_linux_map_for_section(proc_handle_t *handle, const char* secname, const c
720720
}
721721

722722
const char *path = line + path_pos;
723+
if (path[0] == '[' && path[strlen(path)-1] == ']') {
724+
// Skip [heap], [stack], [anon:cpython:pymalloc], etc.
725+
continue;
726+
}
727+
723728
const char *filename = strrchr(path, '/');
724729
if (filename) {
725730
filename++; // Move past the '/'

0 commit comments

Comments
 (0)