开发过程中使用ASIHTTPRequest,基本配置已配好(如文件导入、框架导入等),但使用时在ASIHTTPRequest.m文件中的如下代码处停滞,问一下各位大牛这是什么原因,该怎么样解决呢?谢谢!
停滞处代码如下:
/* ALWAYS CALLED ON MAIN THREAD! */
– (void)reportFailure
{
if (delegate && [delegate respondsToSelector:didFailSelector]) { //停滞在此行
[delegate performSelector:didFailSelector withObject:self];
}
#if NS_BLOCKS_AVAILABLE
if(failureBlock){
failureBlock();
}
#endif
if (queue && [queue respondsToSelector:@selector(requestFailed:)]) {
[queue performSelector:@selector(requestFailed:) withObject:self];
}
}
停滞处代码如下:
/* ALWAYS CALLED ON MAIN THREAD! */
– (void)reportFailure
{
if (delegate && [delegate respondsToSelector:didFailSelector]) { //停滞在此行
[delegate performSelector:didFailSelector withObject:self];
}
#if NS_BLOCKS_AVAILABLE
if(failureBlock){
failureBlock();
}
#endif
if (queue && [queue respondsToSelector:@selector(requestFailed:)]) {
[queue performSelector:@selector(requestFailed:) withObject:self];
}
}
解决方案