Para actualizar la ubicación de un indicador GPS en MAPview ...
[mapView removeAnnotation:myGpsAnnotation];
[myGpsAnnotation release];
myGpsAnnotation = nil;
myGpsAnnotation = [[MapLocationAnnotation alloc] initWithCoordinate:region.center annotationType:MapAnnotationTypeGps title:MAP_ANNOTATION_TYPE_GPS];
[mapView addAnnotation:myGpsAnnotation];
... Veo la memoria neta subiendo lentamente en Instrumentos (simulador). Sin blip fugas, pero Net Bytes y # Net incrementando lentamente ... a menos que este código está comentado. Así que estoy 100% seguro de que este es el código erróneo.
Pero si lo hago la siguiente ...
[mapView removeAnnotation:myGpsAnnotation];
[myGpsAnnotation release];
myGpsAnnotation = nil;
myGpsAnnotation = [[MapLocationAnnotation alloc] initWithCoordinate:region.center annotationType:MapAnnotationTypeGps title:MAP_ANNOTATION_TYPE_GPS];
[mapView addAnnotation:myGpsAnnotation];
[mapView removeAnnotation:myGpsAnnotation];
[mapView addAnnotation:myGpsAnnotation];
[mapView removeAnnotation:myGpsAnnotation];
[mapView addAnnotation:myGpsAnnotation];
... entonces la red Bytes y # Net aumentar mucho más rápido. ¿Es posible que esto no es mi error, y estoy tratando de localizar una fuga en MapKit? ¿De verdad estoy perdiendo memoria? Una vez más, no aparece nada en fugas, pero entonces no veo por qué los valores netos estarían subiendo continuamente.
Gracias por cualquier ayuda, -Gord













