Error while doing FQLRequest
I am doing a FQL request when in my view controller through a specific method. Here is my request.
NSString* fql = [[NSString alloc] init];
fql = [NSString stringWithFormat:@"SELECT uid, name FROM user WHERE uid IN(SELECT uid FROM event_member WHERE eid= %@) AND sex='female'", event_id];
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObject:fql forKey:@"query"];
[[Facebook shared] requestWithMethodName:@"fql.query" andParams:params andHttpMethod:@"POST" andDelegate: self];
[fql release];
However, when I just launch my request a second time, I got that error when using NSZombieEnabled :
-[CFString release]: message sent to deallocated instance 0x4cb9ec0
The thread points at [_params release] in FBRequest.m
When trying just changing the request with
fql = @"SELECT uid, name, sex FROM user WHERE uid IN (SELECT uid2 FROM friend WHERE uid1 = me()) AND sex = 'male'";
I have no longer the error.
Here are the fbrequest delegate methods
- (void)request:(FBRequest *)request didReceiveResponse:(NSURL开发者_运维技巧Response *)response {
NSLog(@"FBRequestDelegate Received response");
}
- (void)request:(FBRequest *)request didLoad:(id)result {
NSLog(@"FBRequestDidLoad Received response");
self.allListProfils = result;
NSLog(@"all listprofil :%@", allListProfils);
[self resetSearch];
[DSBezelActivityView removeViewAnimated:YES];
moreButton.hidden = NO;
[table reloadData];
};
- (void)request:(FBRequest *)request didFailWithError:(NSError *)error {
NSLog(@"FBRequestDidFailWithError Received response, Error is : %@",[error description]);
};
Does it ring a bell for some of you ?
Thanks :)
精彩评论