gh-142627: Ignore anonymous mappings in Linux remote debugging (#142628)

This commit is contained in:
Victor Stinner 2025-12-12 14:12:11 +01:00 committed by GitHub
parent 7aa353c414
commit e0bca091a4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -722,6 +722,11 @@ search_linux_map_for_section(proc_handle_t *handle, const char* secname, const c
}
const char *path = line + path_pos;
if (path[0] == '[' && path[strlen(path)-1] == ']') {
// Skip [heap], [stack], [anon:cpython:pymalloc], etc.
continue;
}
const char *filename = strrchr(path, '/');
if (filename) {
filename++; // Move past the '/'