Skip to content

Commit

Permalink
Maintain original apk structure, by skipping compat functions
Browse files Browse the repository at this point in the history
 - Apktool goal is to match original apk, if it changes apk
 it breaks this goal. Skip these functions
  • Loading branch information
iBotPeaches committed Aug 14, 2015
1 parent 0e5dead commit 7bff185
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tools/aapt/ResourceTable.cpp
Expand Up @@ -4451,6 +4451,8 @@ static int getMinSdkVersion(const Bundle* bundle) {
* attribute will be respected.
*/
status_t ResourceTable::modifyForCompat(const Bundle* bundle) {
return NO_ERROR;

const int minSdk = getMinSdkVersion(bundle);
if (minSdk >= SDK_LOLLIPOP_MR1) {
// Lollipop MR1 and up handles public attributes differently, no
Expand Down Expand Up @@ -4587,6 +4589,8 @@ status_t ResourceTable::modifyForCompat(const Bundle* bundle,
const String16& resourceName,
const sp<AaptFile>& target,
const sp<XMLNode>& root) {
return NO_ERROR;

const int minSdk = getMinSdkVersion(bundle);
if (minSdk >= SDK_LOLLIPOP_MR1) {
// Lollipop MR1 and up handles public attributes differently, no
Expand Down

0 comments on commit 7bff185

Please sign in to comment.