|
|
@@ -71,8 +71,9 @@ static kern_return_t reader(__unused task_t remote_task, vm_address_t remote_add
|
|
|
for (unsigned int i = 0; i < zoneCount; i++) {
|
|
|
malloc_zone_t *zone = (malloc_zone_t *)zones[i];
|
|
|
malloc_introspection_t *introspection = zone->introspect;
|
|
|
+ NSString *zoneName = @(zone->zone_name);
|
|
|
|
|
|
- if (!introspection) {
|
|
|
+ if (![zoneName isEqualToString:@"DefaultMallocZone"] || !introspection) {
|
|
|
continue;
|
|
|
}
|
|
|
|
|
|
@@ -107,6 +108,9 @@ static kern_return_t reader(__unused task_t remote_task, vm_address_t remote_add
|
|
|
introspection->enumerator(TASK_NULL, (void *)&callback, MALLOC_PTR_IN_USE_RANGE_TYPE, (vm_address_t)zone, reader, &range_callback);
|
|
|
unlock_zone(zone);
|
|
|
}
|
|
|
+
|
|
|
+ // Only one zone to enumerate
|
|
|
+ break;
|
|
|
}
|
|
|
}
|
|
|
}
|