Skip to content

Commit

Permalink
Fix null pointer
Browse files Browse the repository at this point in the history
When I am decompiling an apk, I got this exception:
Exception in thread "main" java.lang.NullPointerException
        at brut.androlib.res.data.ResResSpec.<init>(ResResSpec.java:42)
  • Loading branch information
a-bahmani authored Dec 17, 2018
1 parent 3cf5cb6 commit db553eb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public ResResSpec(ResID id, String name, ResPackage pkg, ResTypeSpec type) {
if (resResSpec != null) {
cleanName = name + "_APKTOOL_DUPLICATENAME_" + id.toString();
} else {
cleanName = (name.isEmpty() ? ("APKTOOL_DUMMYVAL_" + id.toString()) : name);
cleanName = ((name == null || name.isEmpty()) ? ("APKTOOL_DUMMYVAL_" + id.toString()) : name);
}

this.mName = cleanName;
Expand Down

0 comments on commit db553eb

Please sign in to comment.