Xcode 7 Objective c Warning - null passed to the called party that requires a non-empty argument

After updating XCODE 7, I get this warning, I try to get rid of it, but I can not find the correct solution:

CFRelease(CFNetworkCopyProxiesForURL((CFURLRef)theURL, NULL));

Warning:

Zero passed to the called party, which requires a non-empty argument

+4
source share
1 answer

Found a hack to get rid of this warning

 NSDictionary *proxySettings = NSMakeCollectable([(NSDictionary *)CFNetworkCopySystemProxySettings() autorelease]);
    CFRelease(CFNetworkCopyProxiesForURL((CFURLRef)theURL, (CFDictionaryRef)proxySettings));
+3
source

Source: https://habr.com/ru/post/1650759/


All Articles