sky201503 / android-apktool-1

Automatically exported from code.google.com/p/android-apktool

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NullPointerException while decoding APK

GoogleCodeExporter opened this issue · comments

I: Baksmaling...
I: Loading resource table...
I: Loaded.
I: Decoding AndroidManifest.xml with resources...
W: Could not decode attr value, using undecoded value instead: ns=android, 
name=versionCode, value=0x00000001
W: Could not decode attr value, using undecoded value instead: ns=android, 
name=versionName, value=0x0000001c
Exception in thread "main" java.lang.NullPointerException
    at java.io.Writer.write(Writer.java:157)
    at brut.androlib.res.util.ExtMXSerializer.writeAttributeValue(ExtMXSerializer.java:38)
    at org.xmlpull.mxp1_serializer.MXSerializer.attribute(MXSerializer.java:673)
    at org.xmlpull.v1.wrapper.classic.XmlSerializerDelegate.attribute(XmlSerializerDelegate.java:106)
    at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.writeStartTag(StaticXmlSerializerWrapper.java:267)
    at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.event(StaticXmlSerializerWrapper.java:211)
    at brut.androlib.res.decoder.XmlPullStreamDecoder$1.event(XmlPullStreamDecoder.java:64)
    at brut.androlib.res.decoder.XmlPullStreamDecoder.decode(XmlPullStreamDecoder.java:98)
    at brut.androlib.res.decoder.XmlPullStreamDecoder.decodeManifest(XmlPullStreamDecoder.java:112)
    at brut.androlib.res.decoder.ResFileDecoder.decodeManifest(ResFileDecoder.java:126)
    at brut.androlib.res.AndrolibResources.decode(AndrolibResources.java:152)
    at brut.androlib.Androlib.decodeResourcesFull(Androlib.java:113)
    at brut.androlib.ApkDecoder.decode(ApkDecoder.java:99)
    at brut.apktool.Main.cmdDecode(Main.java:131)
    at brut.apktool.Main.main(Main.java:68)


APK attached. What are we doing wrong?

Original issue reported on code.google.com by ru...@savanne.be on 10 Dec 2012 at 5:23

Attachments:

Your missing FrameworkFiles

Original comment by connor.tumbleson on 10 Dec 2012 at 10:55

  • Changed state: Waiting_For_Issuer
Is there a way to determine which ones I'm missing? This should be a standard 
Android app.

Original comment by ru...@savanne.be on 11 Dec 2012 at 6:11

Turns out it was missing the 1.apk which is supposed to be embedded. This one 
probably couldn't be installed because the user that was running apktool does 
not have write permissions on the server it was running on.

Could be nice to have an actual warning rather than a NPE.

Works like a charm now though, thanks for the help!

Original comment by ru...@savanne.be on 11 Dec 2012 at 7:07

This is the best indication without rewriting core parts of Apktool.

W: Could not decode attr value, using undecoded value instead: ns=android, 
name=versionCode, value=0x00000001
W: Could not decode attr value, using undecoded value instead: ns=android, 
name=versionName, value=0x0000001c

Original comment by connor.tumbleson on 11 Dec 2012 at 2:41

  • Changed state: Invalid