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

Side by Side Diff: chrome/browser/process_singleton_linux.cc

Issue 46076: Removed zombie hunter code (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/process_singleton.h ('k') | chrome/browser/process_singleton_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/process_singleton.h" 5 #include "chrome/browser/process_singleton.h"
6 6
7 #include <errno.h> 7 #include <errno.h>
8 #include <sys/types.h> 8 #include <sys/types.h>
9 #include <sys/socket.h> 9 #include <sys/socket.h>
10 #include <sys/un.h> 10 #include <sys/un.h>
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 LOG(ERROR) << "bind() failed: " << strerror(errno); 48 LOG(ERROR) << "bind() failed: " << strerror(errno);
49 49
50 if (listen(sock, 5) < 0) 50 if (listen(sock, 5) < 0)
51 NOTREACHED() << "listen failed: " << strerror(errno); 51 NOTREACHED() << "listen failed: " << strerror(errno);
52 52
53 // TODO(port): register this socket as something we care about getting 53 // TODO(port): register this socket as something we care about getting
54 // input on, process messages, etc. 54 // input on, process messages, etc.
55 // http://code.google.com/p/chromium/issues/detail?id=8073 55 // http://code.google.com/p/chromium/issues/detail?id=8073
56 } 56 }
57 57
58 void ProcessSingleton::HuntForZombieChromeProcesses() {
59 // On Windows, this examines all the chrome.exe processes to see if one
60 // is hung. TODO(port): should we do anything here?
61 // http://code.google.com/p/chromium/issues/detail?id=8073
62 }
63
64 void ProcessSingleton::SetupSocket(int* sock, struct sockaddr_un* addr) { 58 void ProcessSingleton::SetupSocket(int* sock, struct sockaddr_un* addr) {
65 *sock = socket(PF_UNIX, SOCK_STREAM, 0); 59 *sock = socket(PF_UNIX, SOCK_STREAM, 0);
66 if (*sock < 0) 60 if (*sock < 0)
67 LOG(FATAL) << "socket() failed: " << strerror(errno); 61 LOG(FATAL) << "socket() failed: " << strerror(errno);
68 62
69 addr->sun_family = AF_UNIX; 63 addr->sun_family = AF_UNIX;
70 base::strlcpy(addr->sun_path, socket_path_.value().c_str(), 64 base::strlcpy(addr->sun_path, socket_path_.value().c_str(),
71 sizeof(addr->sun_path)); 65 sizeof(addr->sun_path));
72 } 66 }
OLDNEW
« no previous file with comments | « chrome/browser/process_singleton.h ('k') | chrome/browser/process_singleton_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698