Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ecc5b436 authored by Nick Kralevich's avatar Nick Kralevich Committed by Android Git Automerger
Browse files

am 745a42bb: Merge "aapt: add support for optional uses-permission" into jb-mr2-dev

* commit '745a42bb':
  aapt: add support for optional uses-permission
parents 21af446c 745a42bb
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -592,6 +592,10 @@ int doDump(Bundle* bundle)
                        goto bail;
                    }
                    printf("uses-permission: %s\n", name.string());
                    int req = getIntegerAttribute(tree, REQUIRED_ATTR, NULL, 1);
                    if (!req) {
                        printf("optional-permission: %s\n", name.string());
                    }
                }
            }
        } else if (strcmp("badging", option) == 0) {
@@ -1033,6 +1037,10 @@ int doDump(Bundle* bundle)
                                hasWriteCallLogPermission = true;
                            }
                            printf("uses-permission:'%s'\n", name.string());
                            int req = getIntegerAttribute(tree, REQUIRED_ATTR, NULL, 1);
                            if (!req) {
                                printf("optional-permission:'%s'\n", name.string());
                            }
                        } else {
                            fprintf(stderr, "ERROR getting 'android:name' attribute: %s\n",
                                    error.string());