VirtualBox

Changeset 98477 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Feb 3, 2023 10:37:40 PM (23 months ago)
Author:
vboxsync
Message:

VBoxBugReport: Collect hardening logs too. duh. bugref:8169

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxBugReport/VBoxBugReport.cpp

    r98320 r98477  
    624624    report->addItem(new BugReportCommand("HostUsbDevices", g_pszVBoxManage, "list", "usbhost", NULL));
    625625    report->addItem(new BugReportCommand("HostUsbFilters", g_pszVBoxManage, "list", "usbfilters", NULL));
     626
    626627    for (MachineInfoList::iterator it = machines.begin(); it != machines.end(); ++it)
    627628    {
    628         VBRDir VmDir(PathJoin((*it)->getLogPath(), "VBox.log*"));
    629         const char *pcszVmLogFile = VmDir.next();
    630         while (pcszVmLogFile)
     629        static const char * const s_apszLogFilePatterns[] = { "VBox.log*", "VBoxHardening.log" };
     630        for (size_t iPat = 0; iPat < RT_ELEMENTS(s_apszLogFilePatterns); iPat++)
    631631        {
    632             report->addItem(new BugReportFile(PathJoin((*it)->getLogPath(), pcszVmLogFile),
    633                                               PathJoin((*it)->getName(), pcszVmLogFile)));
    634             pcszVmLogFile = VmDir.next();
     632            VBRDir VmLogFiles(PathJoin((*it)->getLogPath(), s_apszLogFilePatterns[iPat]));
     633            const char *pcszVmLogFile = VmLogFiles.next();
     634            while (pcszVmLogFile)
     635            {
     636                report->addItem(new BugReportFile(PathJoin((*it)->getLogPath(), pcszVmLogFile),
     637                                                  PathJoin((*it)->getName(), pcszVmLogFile)));
     638                pcszVmLogFile = VmLogFiles.next();
     639            }
    635640        }
    636641        report->addItem(new BugReportFile((*it)->getSettingsFile(),
    637                                          PathJoin((*it)->getName(), RTPathFilename((*it)->getSettingsFile()))));
     642                                          PathJoin((*it)->getName(), RTPathFilename((*it)->getSettingsFile()))));
    638643        report->addItem(new BugReportCommand(PathJoin((*it)->getName(), "GuestProperties"),
    639                                             g_pszVBoxManage, "guestproperty", "enumerate",
    640                                             (*it)->getName(), NULL));
     644                                             g_pszVBoxManage, "guestproperty", "enumerate",
     645                                             (*it)->getName(), NULL));
    641646    }
    642647
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette