Unity3d 4.6.2 version il2cpp zip compression bug in the compilation environment

Source: Internet
Author: User

Recently updated to the latest version of Unity3d, this issue was discovered when using Il2cpp to publish 64-bit iOS apps. It resulted in my original encrypted files can not be extracted, checked the day, fixed.


1. Download the zip's original code on GitHub, Https://codeload.github.com/0xd4d/de4dot/zip/master

2. Directly under the Unity3d project, compile, the compiler will directly overwrite the system's own zip.

3. Modify the source file: ~/zip/compression/streams/streammanipulator.cs

From

Buffer_ |= (UINT) ((window_[windowstart_++] & 0xFF | (window_[windowstart_++] & 0xff) << 8) << bitsinbuffer_);

To

byte [] abuf = new Byte[2];abuf[0] = window_[windowstart_++];abuf[1] = Window_[windowstart_++];buffer_ |= (UINT) (((aBuf[0 ] & 0xff) | ((Abuf[1] & 0xff) << 8)) << bitsinbuffer_);

PS: This problem, can be said to be il2cpp the problem of compiling, also can say this line of code write compatibility is not very good, see understand it!


Job opportunities for big companies!

Unity3d 4.6.2 version il2cpp zip compression bug in the compilation environment

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.