[This is not a DLog, it was a separate thread. See Edits / Comments below]
Xcode 4.3 I use a common preprocessor macro to debug logging:
#ifdef DEBUG # define DLog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); #else # define DLog(...) #endif
Compiles / works fine under iOS 5.0, but when I run it under iOS 4.3, I get a ton of "autoreleased without a pool in place - just a leak" whenever a DLog runs. I tried rebooting, it did not help.
Am I pursuing, or is there a solution? TIA.
[edit 1]
Forgot to mention this ARC project. The only default startup pool is main.m:
@autoreleasepool { int retVal = UIApplicationMain(argc, argv, nil, nil); return retVal; }
There is nothing special about my use of DLog, because errors are triggered when the application starts, when I just put
DLog(@"didFinishLaunchingWithOptions");
[edit 2]
Sorry, this is not the DLog causing the problem. Here is the first line that will call this for me:
BOOL customDates = [[defaults objectForKey:@"custom_dates"] boolValue];
Console Reports:
* __NSAutoreleaseNoPool (): An 0x15cca20 object of the NSCFBoolean class is auto-implemented without a pool in place - just a leak
I am still confused by all these leak reports because I thought we did not need to worry about auto-detection using ARC. So what is the problem?