libimobiledevice / libplist

A library to handle Apple Property List format in binary or XML
https://libimobiledevice.org
GNU Lesser General Public License v2.1
546 stars 305 forks source link

Integers are truncated on mips when converting between bin and xml format #15

Closed hyperair closed 10 years ago

hyperair commented 10 years ago

The test emptycmp fails because 2.plist.out on mips shows 2369772560 instead of 32434543632.

It's truncated at a 32-bit boundary, so it's probably an integer size issue.

The issue is in plist_to_bin() rather than plist_from_bin(), because doing the xml->bin conversion on amd64 and then using that bin file for converting back to xml on mips succeeds (except for the timezone issue mentioned in #14).

hyperair commented 10 years ago

Okay, I just cleaned the entire tree and rebuilt. This bug doesn't seem to occur any more, so I think it might have been due to some stale object files lying around after fixing #13.

nikias commented 10 years ago

Hm interesting. I wonder how the endianess fix solved the truncation?