diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-05 17:21:11 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-05 17:21:11 +0100 |
commit | 64c5d35aebc38f93ce5c086c15c15de5acb21b2f (patch) | |
tree | 51113a991ff0111cddcf65bca90ac995e2173c1b /lib/Plugins/KerneloopsReporter.cpp | |
parent | 01f36609ba1631751e492784d95b0e6b0706cf45 (diff) | |
download | abrt-64c5d35aebc38f93ce5c086c15c15de5acb21b2f.tar.gz abrt-64c5d35aebc38f93ce5c086c15c15de5acb21b2f.tar.xz abrt-64c5d35aebc38f93ce5c086c15c15de5acb21b2f.zip |
InformAllUsers support. enabled by default for Kerneloops. Tested wuth CCpp.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'lib/Plugins/KerneloopsReporter.cpp')
-rw-r--r-- | lib/Plugins/KerneloopsReporter.cpp | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lib/Plugins/KerneloopsReporter.cpp b/lib/Plugins/KerneloopsReporter.cpp index c57a1ef..712adf0 100644 --- a/lib/Plugins/KerneloopsReporter.cpp +++ b/lib/Plugins/KerneloopsReporter.cpp @@ -98,12 +98,10 @@ std::string CKerneloopsReporter::Report(const map_crash_report_t& pCrashReport, const std::string& pArgs) { int ret = -1; - map_crash_report_t::const_iterator it; update_client(_("Creating and submitting a report...")); - it = pCrashReport.begin(); - it = pCrashReport.find(FILENAME_KERNELOOPS); + map_crash_report_t::const_iterator it = pCrashReport.find(FILENAME_KERNELOOPS); if (it != pCrashReport.end()) { ret = http_post_to_kerneloops_site( m_sSubmitURL.c_str(), @@ -111,19 +109,18 @@ std::string CKerneloopsReporter::Report(const map_crash_report_t& pCrashReport, ); } - if (ret) - { + if (ret) { /* FIXME: be more informative */ - throw CABRTException(EXCEP_PLUGIN, std::string("CKerneloopsReporter::Report(): Report has not been sent...")); + throw CABRTException(EXCEP_PLUGIN, std::string("CKerneloopsReporter::Report(): Report has not been sent...")); } return "Kernel oops report was uploaded to: " + m_sSubmitURL; } void CKerneloopsReporter::SetSettings(const map_plugin_settings_t& pSettings) { - if (pSettings.find("SubmitURL") != pSettings.end()) - { - m_sSubmitURL = pSettings.find("SubmitURL")->second; + map_plugin_settings_t::const_iterator it = pSettings.find("SubmitURL"); + if (it != pSettings.end()) { + m_sSubmitURL = it->second; } } |