I'm getting the error "passing address of non-local object to _autoreleasing parameter for write back" when i'm trying to access the particular method.
Code:
(void)resetProgressDelegate:(id __strong *)progressDelegate
{
#if !TARGET_OS_IPHONE
// If the uploadProgressDelegate is an NSProgressIndicator, we set its MaxValue to 1.0 so we can treat it similarly to UIProgressViews
SEL selector = @selector(setMaxValue:);
if ([*progressDelegate respondsToSelector:selector]) {
double max = 1.0;
[ASIHTTPRequest performSelector:selector onTarget:progressDelegate withObject:nil amount:&max callerToRetain:nil];
}
selector = @selector(setDoubleValue:);
if ([*progressDelegate respondsToSelector:selector]) {
double value = 0.0;
[ASIHTTPRequest performSelector:selector onTarget:progressDelegate withObject:nil amount:&value callerToRetain:nil];
}
#else
SEL selector = @selector(setProgress:);
if ([*progressDelegate respondsToSelector:selector]) {
float value = 0.0f;
[ASIHTTPRequest performSelector:selector onTarget:progressDelegate withObject:nil amount:&value callerToRetain:nil];
}
#endif
}
(void)setUploadProgressDelegate:(id)newDelegate
{
uploadProgressDelegate = newDelegate;
[self resetProgressDelegate: &uploadProgressDelegate];
}
[self resetProgressDelegate: &uploadProgressDelegate];