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

Side by Side Diff: net/tools/net_watcher/net_watcher.cc

Issue 15792013: net_watcher does not build in Ubuntu 13.04 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change to pragma Created 7 years, 6 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
« no previous file with comments | « no previous file | no next file » | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // This is a small utility that watches for and logs network changes. 5 // This is a small utility that watches for and logs network changes.
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 127
128 } // namespace 128 } // namespace
129 129
130 int main(int argc, char* argv[]) { 130 int main(int argc, char* argv[]) {
131 #if defined(OS_MACOSX) 131 #if defined(OS_MACOSX)
132 base::mac::ScopedNSAutoreleasePool pool; 132 base::mac::ScopedNSAutoreleasePool pool;
133 #endif 133 #endif
134 #if (defined(OS_LINUX) || defined(OS_OPENBSD)) && !defined(OS_CHROMEOS) 134 #if (defined(OS_LINUX) || defined(OS_OPENBSD)) && !defined(OS_CHROMEOS)
135 // Needed so ProxyConfigServiceLinux can use gconf. 135 // Needed so ProxyConfigServiceLinux can use gconf.
136 // Normally handled by BrowserMainLoop::InitializeToolkit(). 136 // Normally handled by BrowserMainLoop::InitializeToolkit().
137 // From glib version 2.36 onwards, g_type_init is implicitly called and it is
138 // deprecated.
139 #pragma GCC diagnostic push
140 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
137 g_type_init(); 141 g_type_init();
142 #pragma GCC diagnostic pop
138 #endif 143 #endif
139 base::AtExitManager exit_manager; 144 base::AtExitManager exit_manager;
140 CommandLine::Init(argc, argv); 145 CommandLine::Init(argc, argv);
141 logging::InitLogging( 146 logging::InitLogging(
142 NULL, 147 NULL,
143 logging::LOG_ONLY_TO_SYSTEM_DEBUG_LOG, 148 logging::LOG_ONLY_TO_SYSTEM_DEBUG_LOG,
144 logging::LOCK_LOG_FILE, 149 logging::LOCK_LOG_FILE,
145 logging::DELETE_OLD_LOG_FILE, 150 logging::DELETE_OLD_LOG_FILE,
146 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS); 151 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS);
147 152
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 proxy_config_service->RemoveObserver(&net_watcher); 193 proxy_config_service->RemoveObserver(&net_watcher);
189 194
190 // Uses |network_change_notifier|. 195 // Uses |network_change_notifier|.
191 net::NetworkChangeNotifier::RemoveDNSObserver(&net_watcher); 196 net::NetworkChangeNotifier::RemoveDNSObserver(&net_watcher);
192 net::NetworkChangeNotifier::RemoveConnectionTypeObserver(&net_watcher); 197 net::NetworkChangeNotifier::RemoveConnectionTypeObserver(&net_watcher);
193 net::NetworkChangeNotifier::RemoveIPAddressObserver(&net_watcher); 198 net::NetworkChangeNotifier::RemoveIPAddressObserver(&net_watcher);
194 net::NetworkChangeNotifier::RemoveNetworkChangeObserver(&net_watcher); 199 net::NetworkChangeNotifier::RemoveNetworkChangeObserver(&net_watcher);
195 200
196 return 0; 201 return 0;
197 } 202 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698