Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(236)

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 10949027: Close leaking FDs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed last comments and synced. Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | content/app/android/sandboxed_process_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index bb4d4d545fb342b89eb2322f1c511289bdbecc49..1a178107f830921c4348f2aafd5b7e1e7d14fa60 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -136,10 +136,12 @@
#include "chrome/browser/ui/crypto_module_password_dialog.h"
#endif
+using base::FileDescriptor;
using content::AccessTokenStore;
using content::BrowserThread;
using content::BrowserURLHandler;
using content::ChildProcessSecurityPolicy;
+using content::FileDescriptorInfo;
using content::QuotaPermissionContext;
using content::RenderViewHost;
using content::SiteInstance;
@@ -1664,11 +1666,12 @@ bool ChromeContentBrowserClient::AllowPepperPrivateFileAPI() {
#if defined(OS_POSIX) && !defined(OS_MACOSX)
void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess(
const CommandLine& command_line,
- base::GlobalDescriptors::Mapping* mappings) {
+ std::vector<FileDescriptorInfo>* mappings) {
int crash_signal_fd = GetCrashSignalFD(command_line);
if (crash_signal_fd >= 0) {
- mappings->push_back(std::pair<base::GlobalDescriptors::Key, int>(
- kCrashDumpSignal, crash_signal_fd));
+ mappings->push_back(FileDescriptorInfo(kCrashDumpSignal,
+ FileDescriptor(crash_signal_fd,
+ false)));
}
}
#endif // defined(OS_POSIX) && !defined(OS_MACOSX)
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | content/app/android/sandboxed_process_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698