| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/media/webrtc_logging_handler_host.h" | 5 #include "chrome/browser/media/webrtc_logging_handler_host.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 378 #if defined(OS_MACOSX) | 378 #if defined(OS_MACOSX) |
| 379 computer_model = base::mac::GetModelIdentifier(); | 379 computer_model = base::mac::GetModelIdentifier(); |
| 380 #elif defined(OS_CHROMEOS) | 380 #elif defined(OS_CHROMEOS) |
| 381 chromeos::system::StatisticsProvider::GetInstance()-> | 381 chromeos::system::StatisticsProvider::GetInstance()-> |
| 382 GetMachineStatistic(chromeos::system::kHardwareClassKey, &computer_model); | 382 GetMachineStatistic(chromeos::system::kHardwareClassKey, &computer_model); |
| 383 #endif | 383 #endif |
| 384 LogToCircularBuffer("Computer model: " + computer_model); | 384 LogToCircularBuffer("Computer model: " + computer_model); |
| 385 | 385 |
| 386 // GPU | 386 // GPU |
| 387 gpu::GPUInfo gpu_info = content::GpuDataManager::GetInstance()->GetGPUInfo(); | 387 gpu::GPUInfo gpu_info = content::GpuDataManager::GetInstance()->GetGPUInfo(); |
| 388 LogToCircularBuffer("Gpu: machine-model='" + gpu_info.machine_model + | 388 LogToCircularBuffer( |
| 389 "', vendor-id=" + IntToString(gpu_info.gpu.vendor_id) + | 389 "Gpu: machine-model-name='" + gpu_info.machine_model_name + |
| 390 ", device-id=" + IntToString(gpu_info.gpu.device_id) + | 390 "', machine-model-version=" + gpu_info.machine_model_version + |
| 391 ", driver-vendor='" + gpu_info.driver_vendor + | 391 "', vendor-id=" + IntToString(gpu_info.gpu.vendor_id) + |
| 392 "', driver-version=" + gpu_info.driver_version); | 392 ", device-id=" + IntToString(gpu_info.gpu.device_id) + |
| 393 ", driver-vendor='" + gpu_info.driver_vendor + |
| 394 "', driver-version=" + gpu_info.driver_version); |
| 393 | 395 |
| 394 // Network interfaces | 396 // Network interfaces |
| 395 LogToCircularBuffer("Discovered " + IntToString(network_list.size()) + | 397 LogToCircularBuffer("Discovered " + IntToString(network_list.size()) + |
| 396 " network interfaces:"); | 398 " network interfaces:"); |
| 397 for (net::NetworkInterfaceList::const_iterator it = network_list.begin(); | 399 for (net::NetworkInterfaceList::const_iterator it = network_list.begin(); |
| 398 it != network_list.end(); ++it) { | 400 it != network_list.end(); ++it) { |
| 399 LogToCircularBuffer("Name: " + it->friendly_name + ", Address: " + | 401 LogToCircularBuffer("Name: " + it->friendly_name + ", Address: " + |
| 400 IPAddressToSensitiveString(it->address)); | 402 IPAddressToSensitiveString(it->address)); |
| 401 } | 403 } |
| 402 | 404 |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 459 void WebRtcLoggingHandlerHost::FireGenericDoneCallback( | 461 void WebRtcLoggingHandlerHost::FireGenericDoneCallback( |
| 460 GenericDoneCallback* callback, bool success, | 462 GenericDoneCallback* callback, bool success, |
| 461 const std::string& error_message) { | 463 const std::string& error_message) { |
| 462 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 464 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 463 DCHECK(!(*callback).is_null()); | 465 DCHECK(!(*callback).is_null()); |
| 464 content::BrowserThread::PostTask(content::BrowserThread::UI, FROM_HERE, | 466 content::BrowserThread::PostTask(content::BrowserThread::UI, FROM_HERE, |
| 465 base::Bind(*callback, success, | 467 base::Bind(*callback, success, |
| 466 error_message)); | 468 error_message)); |
| 467 (*callback).Reset(); | 469 (*callback).Reset(); |
| 468 } | 470 } |
| OLD | NEW |