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

Side by Side Diff: net/base/address_list.cc

Issue 199105: Continue with the FreeBSD port - this version builds and links, though... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media/media.gyp ('k') | net/base/ev_root_ca_metadata.h » ('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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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/base/address_list.h" 5 #include "net/base/address_list.h"
6 6
7 #ifdef OS_WIN 7 #ifdef OS_WIN
8 #include <ws2tcpip.h> 8 #include <ws2tcpip.h>
9 #include <wspiapi.h> // Needed for Win2k compat. 9 #include <wspiapi.h> // Needed for Win2k compat.
10 #else 10 #else
11 #include <netdb.h> 11 #include <netdb.h>
12 #endif 12 #endif
13 #include <stdlib.h> 13 #include <stdlib.h>
14 14
15 #if defined(OS_FREEBSD)
16 #include <netinet/in.h>
17 #include <sys/socket.h>
18 #endif
19
15 #include "base/logging.h" 20 #include "base/logging.h"
16 21
17 namespace net { 22 namespace net {
18 23
19 namespace { 24 namespace {
20 25
21 // Make a deep copy of |info|. This copy should be deleted using 26 // Make a deep copy of |info|. This copy should be deleted using
22 // DeleteCopyOfAddrinfo(), and NOT freeaddrinfo(). 27 // DeleteCopyOfAddrinfo(), and NOT freeaddrinfo().
23 struct addrinfo* CreateCopyOfAddrinfo(const struct addrinfo* info) { 28 struct addrinfo* CreateCopyOfAddrinfo(const struct addrinfo* info) {
24 struct addrinfo* copy = new struct addrinfo; 29 struct addrinfo* copy = new struct addrinfo;
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 AddressList::Data::~Data() { 155 AddressList::Data::~Data() {
151 // Call either freeaddrinfo(head), or FreeMyAddrinfo(head), depending who 156 // Call either freeaddrinfo(head), or FreeMyAddrinfo(head), depending who
152 // created the data. 157 // created the data.
153 if (is_system_created) 158 if (is_system_created)
154 freeaddrinfo(head); 159 freeaddrinfo(head);
155 else 160 else
156 FreeMyAddrinfo(head); 161 FreeMyAddrinfo(head);
157 } 162 }
158 163
159 } // namespace net 164 } // namespace net
OLDNEW
« no previous file with comments | « media/media.gyp ('k') | net/base/ev_root_ca_metadata.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698