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

Side by Side Diff: net/proxy/proxy_config_service_linux.cc

Issue 7215027: Coverity: Initialize member variables. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « net/base/listen_socket.cc ('k') | net/socket/ssl_client_socket_pool.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "net/proxy/proxy_config_service_linux.h" 5 #include "net/proxy/proxy_config_service_linux.h"
6 6
7 #include <errno.h> 7 #include <errno.h>
8 #include <fcntl.h> 8 #include <fcntl.h>
9 #if defined(USE_GCONF) 9 #if defined(USE_GCONF)
10 #include <gconf/gconf-client.h> 10 #include <gconf/gconf-client.h>
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 485
486 DISALLOW_COPY_AND_ASSIGN(SettingGetterImplGConf); 486 DISALLOW_COPY_AND_ASSIGN(SettingGetterImplGConf);
487 }; 487 };
488 #endif // defined(USE_GCONF) 488 #endif // defined(USE_GCONF)
489 489
490 #if defined(USE_GIO) 490 #if defined(USE_GIO)
491 // This setting getter uses gsettings, as used in most GNOME 3 desktops. 491 // This setting getter uses gsettings, as used in most GNOME 3 desktops.
492 class SettingGetterImplGSettings 492 class SettingGetterImplGSettings
493 : public ProxyConfigServiceLinux::SettingGetter { 493 : public ProxyConfigServiceLinux::SettingGetter {
494 public: 494 public:
495 SettingGetterImplGSettings() 495 #if 0
496 : client_(NULL), notify_delegate_(NULL), loop_(NULL) { 496 GSettings* (*g_settings_new)(const gchar* schema);
Mike Mammarella 2011/09/23 20:27:26 Hey, what's with this #if 0 block?
James Hawkins 2011/09/26 03:13:14 Dead, temporary code. Should be removed.
497 GSettings* (*g_settings_get_child)(GSettings* settings, const gchar* name);
498 gboolean (*g_settings_get_boolean)(GSettings* settings, const gchar* key);
499 gchar* (*g_settings_get_string)(GSettings* settings, const gchar* key);
500 gint (*g_settings_get_int)(GSettings* settings, const gchar* key);
501 gchar** (*g_settings_get_strv)(GSettings* settings, const gchar* key);
502 const gchar* const* (*g_settings_list_schemas)();
503
504 // The library handle.
505 void* gio_handle_;
506 #endif
507 SettingGetterImplGSettings() :
497 #if defined(DLOPEN_GSETTINGS) 508 #if defined(DLOPEN_GSETTINGS)
498 gio_handle_ = NULL; 509 g_settings_new(NULL),
510 g_settings_get_child(NULL),
511 g_settings_get_boolean(NULL),
512 g_settings_get_string(NULL),
513 g_settings_get_int(NULL),
514 g_settings_get_strv(NULL),
515 g_settings_list_schemas(NULL),
516 gio_handle_(NULL),
499 #endif 517 #endif
518 client_(NULL),
519 http_client_(NULL),
520 https_client_(NULL),
521 ftp_client_(NULL),
522 socks_client_(NULL),
523 notify_delegate_(NULL),
524 loop_(NULL) {
500 } 525 }
501 526
502 virtual ~SettingGetterImplGSettings() { 527 virtual ~SettingGetterImplGSettings() {
503 // client_ should have been released before now, from 528 // client_ should have been released before now, from
504 // Delegate::OnDestroy(), while running on the UI thread. However 529 // Delegate::OnDestroy(), while running on the UI thread. However
505 // on exiting the process, it may happen that 530 // on exiting the process, it may happen that
506 // Delegate::OnDestroy() task is left pending on the glib loop 531 // Delegate::OnDestroy() task is left pending on the glib loop
507 // after the loop was quit, and pending tasks may then be deleted 532 // after the loop was quit, and pending tasks may then be deleted
508 // without being run. 533 // without being run.
509 if (client_) { 534 if (client_) {
(...skipping 1251 matching lines...) Expand 10 before | Expand all | Expand 10 after
1761 void ProxyConfigServiceLinux::RemoveObserver(Observer* observer) { 1786 void ProxyConfigServiceLinux::RemoveObserver(Observer* observer) {
1762 delegate_->RemoveObserver(observer); 1787 delegate_->RemoveObserver(observer);
1763 } 1788 }
1764 1789
1765 ProxyConfigService::ConfigAvailability 1790 ProxyConfigService::ConfigAvailability
1766 ProxyConfigServiceLinux::GetLatestProxyConfig(ProxyConfig* config) { 1791 ProxyConfigServiceLinux::GetLatestProxyConfig(ProxyConfig* config) {
1767 return delegate_->GetLatestProxyConfig(config); 1792 return delegate_->GetLatestProxyConfig(config);
1768 } 1793 }
1769 1794
1770 } // namespace net 1795 } // namespace net
OLDNEW
« no previous file with comments | « net/base/listen_socket.cc ('k') | net/socket/ssl_client_socket_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698