|
@@ -71,12 +71,10 @@ static kern_return_t reader(__unused task_t remote_task, vm_address_t remote_add
|
|
|
for (unsigned int i = 0; i < zoneCount; i++) {
|
|
for (unsigned int i = 0; i < zoneCount; i++) {
|
|
|
malloc_zone_t *zone = (malloc_zone_t *)zones[i];
|
|
malloc_zone_t *zone = (malloc_zone_t *)zones[i];
|
|
|
malloc_introspection_t *introspection = zone->introspect;
|
|
malloc_introspection_t *introspection = zone->introspect;
|
|
|
- NSString *zoneName = @(zone->zone_name);
|
|
|
|
|
|
|
|
|
|
- // We only need to look at the default malloc zone.
|
|
|
|
|
// This may explain why some zone functions are
|
|
// This may explain why some zone functions are
|
|
|
// sometimes invalid; perhaps not all zones support them?
|
|
// sometimes invalid; perhaps not all zones support them?
|
|
|
- if (![zoneName isEqualToString:@"DefaultMallocZone"] || !introspection) {
|
|
|
|
|
|
|
+ if (!introspection) {
|
|
|
continue;
|
|
continue;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -114,9 +112,6 @@ 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);
|
|
introspection->enumerator(TASK_NULL, (void *)&callback, MALLOC_PTR_IN_USE_RANGE_TYPE, (vm_address_t)zone, reader, &range_callback);
|
|
|
unlock_zone(zone);
|
|
unlock_zone(zone);
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- // Only one zone to enumerate
|
|
|
|
|
- break;
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|