objective-c - iOS开发,获取的二进制数据,在iOS9和iOS8上转化成字典,结果不一致
怪我咯
怪我咯 2017-04-18 09:42:25
0
2
584

从服务器获取到数据,然后解析,但是,将二进制数据转化成字典,在iOS8和iOS9上不一致。
在iOS9上正常,在iOS8上很奇怪。

这是iOS9上的,字典正常:

这是iOS8上的,字典奇葩:

问题:如何让它在iOS8和iOS9上一样?

怪我咯
怪我咯

走同样的路,发现不同的人生

reply all(2)
左手右手慢动作

Try changing options to NSJSONReadingMutableContainers

巴扎黑

You can print two dictionaries separately. If their output data formats are consistent, we can ignore the different internal processing.

I don’t have a test machine of iOS8 at hand, so I can only guess the reason now.
The data (length) returned twice are inconsistent. The system library uses different internal processing methods because of the inconsistent data (length).

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template