diff options
author | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-15 19:22:24 +0000 |
---|---|---|
committer | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-15 19:22:24 +0000 |
commit | 8e1845e1bc61b92e39f21da353fbec0b708e7194 (patch) | |
tree | 03812a0c2da378f45f805c9a436e4adb1d0ad793 /net/base/address_list.h | |
parent | 7a147fb74d7657f42378947a31d24d197d2345db (diff) | |
download | chromium_src-8e1845e1bc61b92e39f21da353fbec0b708e7194.zip chromium_src-8e1845e1bc61b92e39f21da353fbec0b708e7194.tar.gz chromium_src-8e1845e1bc61b92e39f21da353fbec0b708e7194.tar.bz2 |
FBTF: Move code from .h to .cc in net/
Shaves a cumulative 400k off libnet/browser.a
BUG=none
TEST=compiles
Review URL: http://codereview.chromium.org/3432004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59533 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/address_list.h')
-rw-r--r-- | net/base/address_list.h | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/net/base/address_list.h b/net/base/address_list.h index c333f86..9406a8c 100644 --- a/net/base/address_list.h +++ b/net/base/address_list.h @@ -20,13 +20,17 @@ namespace net { class AddressList { public: // Constructs an empty address list. - AddressList() {} + AddressList(); // Constructs an address list for a single IP literal. If // |canonicalize_name| is true, fill the ai_canonname field with the // canonicalized IP address. AddressList(const IPAddressNumber& address, int port, bool canonicalize_name); + AddressList(const AddressList& addresslist); + ~AddressList(); + AddressList& operator=(const AddressList& addresslist); + // Adopt the given addrinfo list (assumed to have been created by // the system, e.g. returned by getaddrinfo()) in place of the // existing one if any. This hands over responsibility for freeing @@ -68,23 +72,12 @@ class AddressList { void Reset(); // Get access to the head of the addrinfo list. - const struct addrinfo* head() const { return data_->head; } + const struct addrinfo* head() const; private: - struct Data : public base::RefCountedThreadSafe<Data> { - Data(struct addrinfo* ai, bool is_system_created); - struct addrinfo* head; - - // Indicates which free function to use for |head|. - bool is_system_created; - - private: - friend class base::RefCountedThreadSafe<Data>; - - ~Data(); - }; + struct Data; - explicit AddressList(Data* data) : data_(data) {} + explicit AddressList(Data* data); scoped_refptr<Data> data_; }; |