OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/bug_report_data.h" | 5 #include "chrome/browser/bug_report_data.h" |
6 | 6 |
7 #include "chrome/browser/browser.h" | 7 #include "chrome/browser/ui/browser.h" |
8 | 8 |
9 #if defined(OS_CHROMEOS) | 9 #if defined(OS_CHROMEOS) |
10 #include "chrome/browser/chromeos/notifications/system_notification.h" | 10 #include "chrome/browser/chromeos/notifications/system_notification.h" |
11 #endif | 11 #endif |
12 | 12 |
13 | 13 |
14 | 14 |
15 #if defined(OS_CHROMEOS) | 15 #if defined(OS_CHROMEOS) |
16 // Called from the same thread as HandleGetDialogDefaults, i.e. the UI thread. | 16 // Called from the same thread as HandleGetDialogDefaults, i.e. the UI thread. |
17 void BugReportData::SyslogsComplete(chromeos::LogDictionaryType* logs, | 17 void BugReportData::SyslogsComplete(chromeos::LogDictionaryType* logs, |
18 std::string* zip_content) { | 18 std::string* zip_content) { |
19 if (sent_report_) { | 19 if (sent_report_) { |
20 // We already sent the report, just delete the data. | 20 // We already sent the report, just delete the data. |
21 if (logs) | 21 if (logs) |
22 delete logs; | 22 delete logs; |
23 if (zip_content) | 23 if (zip_content) |
24 delete zip_content; | 24 delete zip_content; |
25 } else { | 25 } else { |
26 zip_content_ = zip_content; | 26 zip_content_ = zip_content; |
27 sys_info_ = logs; // Will get deleted when SendReport() is called. | 27 sys_info_ = logs; // Will get deleted when SendReport() is called. |
28 if (send_sys_info_) { | 28 if (send_sys_info_) { |
29 // We already prepared the report, send it now. | 29 // We already prepared the report, send it now. |
30 this->SendReport(); | 30 this->SendReport(); |
31 } | 31 } |
32 } | 32 } |
33 } | 33 } |
34 #endif | 34 #endif |
OLD | NEW |