SDURLCache icon indicating copy to clipboard operation
SDURLCache copied to clipboard

Complaints of errors in Xcode 4.3 with the NSCachedURLResponse category

Open samstewart opened this issue 12 years ago • 4 comments

When using Xcode 4.3, a warning message is raised because of the overridden methods in the category on NSCachedURLResponse.

More Info: http://www.iphonedevsdk.com/forum/iphone-sdk-development/99057-new-xcode-4-3-compiler-warnings-categories.html

We've written a simple wrapper instead which conforms to the NSCoding and NSCopying protocols and does not use categories. From our limited testing the approach seems to work and alleviates the error.

samstewart avatar Mar 29 '12 00:03 samstewart

After looking over diff a bit closer I noticed some company code. Let me isolate the fix first.

samstewart avatar Mar 29 '12 00:03 samstewart

OK, removed the proprietary naming scheme so should be all ready to go. We included some other small fixes for code clarity, etc.

samstewart avatar Mar 29 '12 01:03 samstewart

Re-added "lowercaseString" code in most recent commit

samstewart avatar Mar 29 '12 17:03 samstewart

The recent commit fixes an error as described below:


The removal of the NSCachedURLResponse category means that NSKeyedArchiver will throw an EXC_BAD_ACCESS when attempting to load NSCachedURLResponse data. This means that this change requires a cache refresh, and a new cache key namespace that will prevent this from happening. Old cache keys will eventually be evicted from the system as new keys are populated.

samstewart avatar Mar 29 '12 23:03 samstewart