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

Commit 3c4fa103 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Added device name to bugreport file."

parents 14866bbe f8124bd4
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -1505,7 +1505,10 @@ int main(int argc, char *argv[]) {

    if (is_redirecting) {
        ds.bugreport_dir_ = dirname(use_outfile);
        ds.base_name_ = basename(use_outfile);
        std::string build_id = android::base::GetProperty("ro.build.id", "UNKNOWN_BUILD");
        std::string device_name = android::base::GetProperty("ro.product.device", "UNKNOWN_DEVICE");
        ds.base_name_ = android::base::StringPrintf("%s-%s-%s", basename(use_outfile),
                                                    device_name.c_str(), build_id.c_str());
        if (do_add_date) {
            char date[80];
            strftime(date, sizeof(date), "%Y-%m-%d-%H-%M-%S", localtime(&ds.now_));