Vote count:
0
Hello guys i am facing this error and i know what this error is but don't know how can i resolve this exception
and getting this exception on this lines:
NSArray *arrUserInfo=[[NSArray alloc]initWithObjects:strThumbnailImage,strUserId,strUsername,strUserFullName,strUserProfilePic, nil];
[arrUrlImage addObject:arrUserInfo];
-(void)extractDataFromMedia{
@try {
arrDataTemp=[[NSArray alloc]init];
arrDataTemp=[arrMedia valueForKey:@"data"];
NSArray *arr12=[[NSArray alloc]init];
for (arr12 in arrDataTemp)
{
[arrBulkData addObject:arr12];
NSString *strThumbnailImage=[[[arr12 valueForKey:@"images"] valueForKey:@"thumbnail"] valueForKey:@"url"];
NSString *strUserId=[[arr12 valueForKey:@"user"] valueForKey:@"id"];
NSString *strUsername=[[arr12 valueForKey:@"user"] valueForKey:@"username"];
NSString *strUserFullName=[[arr12 valueForKey:@"user"] valueForKey:@"full_name"];
NSString *strUserProfilePic=[[arr12 valueForKey:@"user"] valueForKey:@"profile_picture"];
NSArray *arrUserInfo=[[NSArray alloc]initWithObjects:strThumbnailImage,strUserId,strUsername,strUserFullName,strUserProfilePic, nil];
NSArray *arrPeople=[[NSArray alloc]initWithObjects:strUserId,strUsername,strUserFullName,strUserProfilePic, nil];
if ([strIdentifier isEqualToString:@"Identifier"]) {
NSString *strName,*strLatitude,*strLongitude,*strId;
strName=[[arr12 valueForKey:@"location"] valueForKey:@"name"];
if ([strName isKindOfClass:[NSNull class]] || strName == nil || [strName isEqualToString:@""] || [strName isEqualToString:@"(null)"]) {
}else{
strLatitude=[[arr12 valueForKey:@"location"] valueForKey:@"latitude"];
strLongitude=[[arr12 valueForKey:@"location"] valueForKey:@"longitude"];
strId=[[arr12 valueForKey:@"location"] valueForKey:@"id"];
NSArray *arrLocData=[[NSArray alloc]initWithObjects:strLatitude,strLongitude,strId,strName, nil];
[arrPlacesData addObject:arrLocData];
}
}
[arrUrlImage addObject:arrUserInfo];
[arrUrlPeople addObject:arrPeople];
}
HideNetworkActivityIndicator();
[_collectionView performSelectorOnMainThread:@selector(reloadData) withObject:nil waitUntilDone:YES];
}
@catch (NSException *exception) {
NSLog(@":%@", exception);
}
}
asked 21 secs ago
malloc: *** error for object 0x7feab5a9bf80: pointer being freed was not allocated
Aucun commentaire:
Enregistrer un commentaire