why [response expectedContentLength] always return -1

前端 未结 2 1211
粉色の甜心
粉色の甜心 2020-11-29 04:21
-(void) connection:(NSURLConnection *)connection didReceiveResponse:(NSURLResponse    *)response {
    [UIApplication sharedApplication].networkActivityIndicatorVisi         


        
2条回答
  •  旧时难觅i
    2020-11-29 04:48

    As long as I know, NSURLResponse does not update that property. You need to use NSHTTPURLResponse instead...

提交回复
热议问题