New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StringBlock isn't Thread Safe #711

iBotPeaches opened this Issue Mar 18, 2015 · 1 comment


None yet
1 participant

iBotPeaches commented Mar 18, 2015

Original issue 601 created by on 2014-02-07T13:09:10.000Z:

We are using the apktool in an multithreaded enviroment. When using it single threaded it works fine for us. When running it multithreaded its crashing with the following stack:

java.lang.IllegalStateException: Current state = RESET, new state = FLUSHED
at java.nio.charset.CharsetDecoder.throwIllegalStateException(
at java.nio.charset.CharsetDecoder.flush(
at java.nio.charset.CharsetDecoder.decode(
at brut.androlib.res.decoder.StringBlock.decodeString(
at brut.androlib.res.decoder.StringBlock.getString(
at brut.androlib.res.decoder.ARSCDecoder.readEntry(
at brut.androlib.res.decoder.ARSCDecoder.readConfig(
at brut.androlib.res.decoder.ARSCDecoder.readType(
at brut.androlib.res.decoder.ARSCDecoder.readPackage(
at brut.androlib.res.decoder.ARSCDecoder.readTable(
at brut.androlib.res.decoder.ARSCDecoder.decode(
at brut.androlib.res.AndrolibResources.getResPackagesFromApk(
at brut.androlib.res.AndrolibResources.loadMainPkg(
at brut.androlib.res.AndrolibResources.getResTable(
at brut.androlib.Androlib.getResTable(
at brut.androlib.ApkDecoder.getResTable(

With the attached patch the issue dissappears.


This comment has been minimized.

Show comment
Hide comment

iBotPeaches commented Mar 18, 2015

Comment #1 originally posted by connor.tumbleson on 2014-02-07T13:35:46.000Z:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment