diff options
author | Christian Kamm <mail@ckamm.de> | 2017-05-17 11:55:42 +0300 |
---|---|---|
committer | ckamm <mail@ckamm.de> | 2017-05-17 13:26:27 +0300 |
commit | c8d0f788e00bdae125a26d9159ce9efdd6325cd2 (patch) | |
tree | ad77cb515fe650984e6b76dfffe09838090d77bd /src/crashreporter | |
parent | ae263d60bd6d1bc0eb0c3712bab11de120b8cdd3 (diff) |
Apply clang-format
Diffstat (limited to 'src/crashreporter')
-rw-r--r-- | src/crashreporter/main.cpp | 77 |
1 files changed, 38 insertions, 39 deletions
diff --git a/src/crashreporter/main.cpp b/src/crashreporter/main.cpp index 048b9ff0b..631c211b5 100644 --- a/src/crashreporter/main.cpp +++ b/src/crashreporter/main.cpp @@ -20,18 +20,17 @@ #include <QApplication> #include <QDebug> -int main( int argc, char* argv[] ) +int main(int argc, char *argv[]) { - QApplication app( argc, argv ); + QApplication app(argc, argv); - if ( app.arguments().size() != 2 ) - { + if (app.arguments().size() != 2) { qDebug() << "You need to pass the .dmp file path as only argument"; return 1; } // TODO: install socorro .... - CrashReporter reporter( QUrl( CRASHREPORTER_SUBMIT_URL ), app.arguments() ); + CrashReporter reporter(QUrl(CRASHREPORTER_SUBMIT_URL), app.arguments()); #ifdef CRASHREPORTER_ICON reporter.setLogo(QPixmap(CRASHREPORTER_ICON)); @@ -39,47 +38,47 @@ int main( int argc, char* argv[] ) reporter.setWindowTitle(CRASHREPORTER_PRODUCT_NAME); reporter.setText("<html><head/><body><p><span style=\" font-weight:600;\">Sorry!</span> " CRASHREPORTER_PRODUCT_NAME " crashed. Please tell us about it! " CRASHREPORTER_PRODUCT_NAME " has created an error report for you that can help improve the stability in the future. You can now send this report directly to the " CRASHREPORTER_PRODUCT_NAME " developers.</p></body></html>"); - reporter.setReportData( "BuildID", CRASHREPORTER_BUILD_ID ); - reporter.setReportData( "ProductName", CRASHREPORTER_PRODUCT_NAME ); - reporter.setReportData( "Version", CRASHREPORTER_VERSION_STRING ); - reporter.setReportData( "ReleaseChannel", CRASHREPORTER_RELEASE_CHANNEL); + reporter.setReportData("BuildID", CRASHREPORTER_BUILD_ID); + reporter.setReportData("ProductName", CRASHREPORTER_PRODUCT_NAME); + reporter.setReportData("Version", CRASHREPORTER_VERSION_STRING); + reporter.setReportData("ReleaseChannel", CRASHREPORTER_RELEASE_CHANNEL); //reporter.setReportData( "timestamp", QByteArray::number( QDateTime::currentDateTime().toTime_t() ) ); - // add parameters - - // << Pair("InstallTime", "1357622062") - // << Pair("Theme", "classic/1.0") - // << Pair("Version", "30") - // << Pair("id", "{ec8030f7-c20a-464f-9b0e-13a3a9e97384}") - // << Pair("Vendor", "Mozilla") - // << Pair("EMCheckCompatibility", "true") - // << Pair("Throttleable", "0") - // << Pair("URL", "http://code.google.com/p/crashme/") - // << Pair("version", "20.0a1") - // << Pair("CrashTime", "1357770042") - // << Pair("submitted_timestamp", "2013-01-09T22:21:18.646733+00:00") - // << Pair("buildid", "20130107030932") - // << Pair("timestamp", "1357770078.646789") - // << Pair("Notes", "OpenGL: NVIDIA Corporation -- GeForce 8600M GT/PCIe/SSE2 -- 3.3.0 NVIDIA 313.09 -- texture_from_pixmap\r\n") - // << Pair("StartupTime", "1357769913") - // << Pair("FramePoisonSize", "4096") - // << Pair("FramePoisonBase", "7ffffffff0dea000") - // << Pair("Add-ons", "%7B972ce4c6-7e08-4474-a285-3208198ce6fd%7D:20.0a1,crashme%40ted.mielczarek.org:0.4") - // << Pair("SecondsSinceLastCrash", "1831736") - // << Pair("ProductName", "WaterWolf") - // << Pair("legacy_processing", "0") - // << Pair("ProductID", "{ec8030f7-c20a-464f-9b0e-13a3a9e97384}") - - ; + // add parameters + + // << Pair("InstallTime", "1357622062") + // << Pair("Theme", "classic/1.0") + // << Pair("Version", "30") + // << Pair("id", "{ec8030f7-c20a-464f-9b0e-13a3a9e97384}") + // << Pair("Vendor", "Mozilla") + // << Pair("EMCheckCompatibility", "true") + // << Pair("Throttleable", "0") + // << Pair("URL", "http://code.google.com/p/crashme/") + // << Pair("version", "20.0a1") + // << Pair("CrashTime", "1357770042") + // << Pair("submitted_timestamp", "2013-01-09T22:21:18.646733+00:00") + // << Pair("buildid", "20130107030932") + // << Pair("timestamp", "1357770078.646789") + // << Pair("Notes", "OpenGL: NVIDIA Corporation -- GeForce 8600M GT/PCIe/SSE2 -- 3.3.0 NVIDIA 313.09 -- texture_from_pixmap\r\n") + // << Pair("StartupTime", "1357769913") + // << Pair("FramePoisonSize", "4096") + // << Pair("FramePoisonBase", "7ffffffff0dea000") + // << Pair("Add-ons", "%7B972ce4c6-7e08-4474-a285-3208198ce6fd%7D:20.0a1,crashme%40ted.mielczarek.org:0.4") + // << Pair("SecondsSinceLastCrash", "1831736") + // << Pair("ProductName", "WaterWolf") + // << Pair("legacy_processing", "0") + // << Pair("ProductID", "{ec8030f7-c20a-464f-9b0e-13a3a9e97384}") + + ; // TODO: // send log -// QFile logFile( INSERT_FILE_PATH_HERE ); -// logFile.open( QFile::ReadOnly ); -// reporter.setReportData( "upload_file_miralllog", qCompress( logFile.readAll() ), "application/x-gzip", QFileInfo( INSERT_FILE_PATH_HERE ).fileName().toUtf8()); -// logFile.close(); + // QFile logFile( INSERT_FILE_PATH_HERE ); + // logFile.open( QFile::ReadOnly ); + // reporter.setReportData( "upload_file_miralllog", qCompress( logFile.readAll() ), "application/x-gzip", QFileInfo( INSERT_FILE_PATH_HERE ).fileName().toUtf8()); + // logFile.close(); reporter.show(); |