Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- why is this while loop causing 100% cpu
- [self performSelectorInBackground:@selector(checkstate:) withObject:padid];
- -(void)checkstate:(PadIDSIdentifier*)pids
- {
- int pid=0;
- int cid=0;
- pid=pids.padid;
- cid=pids.channelid;
- NSAutoreleasePool *pool=[[NSAutoreleasePool alloc]init];
- while (change==NO)
- {
- // wait for the condition I want
- change=YES;
- }
- [pool release];
- }
Add Comment
Please, Sign In to add comment