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

Commit 942c50d1 authored by Felipe Leme's avatar Felipe Leme Committed by Android (Google) Code Review
Browse files

Merge "Fixed usage --receiver-foreground on am call."

parents f5248da5 b0b4aa2d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1118,7 +1118,7 @@ int main(int argc, char *argv[]) {
        if (!path.empty()) {
            ALOGI("Final bugreport path: %s\n", path.c_str());
            std::vector<std::string> am_args = {
                 "--receiver-permission", "android.permission.DUMP",
                 "android.permission.DUMP", "--receiver-foreground",
                 "--ei", "android.intent.extra.PID", std::to_string(getpid()),
                 "--es", "android.intent.extra.BUGREPORT", path
            };
+1 −1
Original line number Diff line number Diff line
@@ -579,7 +579,7 @@ void send_broadcast(const std::string& action, const std::vector<std::string>& a
        fprintf(stderr, "send_broadcast: too many arguments (%d)\n", (int) args.size());
        return;
    }
    const char *am_args[1024] = { "/system/bin/am", "broadcast", "--receiver-foreground",
    const char *am_args[1024] = { "/system/bin/am", "broadcast",
                                  "--user", "0", "-a", action.c_str() };
    size_t am_index = 5; // Starts at the index of last initial value above.
    for (const std::string& arg : args) {