nullic / DPLocalizationManager

Provides way to change localization inside application
MIT License
81 stars 21 forks source link

NSObject+DPLocalization -localize crash on 64-bit iOS 8 #4

Closed aceontech closed 10 years ago

aceontech commented 10 years ago

Hi,

While testing some app compatibility with iOS 8 I came across a crash on this line with exception:

EXC_BAD_ACCESS (code=EXC_I386_GPFLT))

The current implementation fakes a va_list by using [NSArray -getObjects:range:] but this no longer seems to work. I have been testing with the iOS 8 simulators (iPad retina or iPad Air), which both crash on the said line. The iPad 2 simulator doesn't exhibit this problem, probably because it simulates a 32-bit environment, whereas the others simulate 64-bit (my best guess).

I'm using Xcode 6 and iOS 8 GM seed.

I have a hotfix ready, for which I can prepare a pull request if good enough to merge. I'll link it to this issue.

aceontech commented 10 years ago

I checked out the demo project and it makes use of formatting reordering, which complicates my fix.

Does anyone by any chance know of a way to fake a va_list in a reliable/portable way? I tried several variations without success (they all crash in the same way as described above).

aceontech commented 10 years ago

Cool, looks like it's fixed, thanks! Would this warrant a point-release + CocoaPods update?

nullic commented 10 years ago

I've updated CocoaPads

2014-09-30 18:41 GMT+03:00 Alex Manarpies notifications@github.com:

Cool, looks like it's fixed, thanks! Would this warrant a point-release + CocoaPods update?

Reply to this email directly or view it on GitHub https://github.com/nullic/DPLocalizationManager/issues/4#issuecomment-57334022 .