Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(10)

Side by Side Diff: Modules/getaddrinfo.c

Issue 3871: cross and native build of python for mingw32 with distutils
Patch Set: Created 7 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Modules/_freeze_importlib.c ('k') | Modules/getnameinfo.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. 2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 { 225 {
226 unsigned char *q = (unsigned char *)p; 226 unsigned char *q = (unsigned char *)p;
227 while (*q) { 227 while (*q) {
228 if (! isdigit(*q)) 228 if (! isdigit(*q))
229 return NO; 229 return NO;
230 q++; 230 q++;
231 } 231 }
232 return YES; 232 return YES;
233 } 233 }
234 234
235 #ifndef EAI_BADHINTS
236 # define EAI_BADHINTS EAI_BADFLAGS
237 #endif
235 int 238 int
236 getaddrinfo(const char*hostname, const char*servname, 239 getaddrinfo(const char*hostname, const char*servname,
237 const struct addrinfo *hints, struct addrinfo **res) 240 const struct addrinfo *hints, struct addrinfo **res)
238 { 241 {
239 struct addrinfo sentinel; 242 struct addrinfo sentinel;
240 struct addrinfo *top = NULL; 243 struct addrinfo *top = NULL;
241 struct addrinfo *cur; 244 struct addrinfo *cur;
242 int i, error = 0; 245 int i, error = 0;
243 char pton[PTON_MAX]; 246 char pton[PTON_MAX];
244 struct addrinfo ai; 247 struct addrinfo ai;
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 if (top) 632 if (top)
630 freeaddrinfo(top); 633 freeaddrinfo(top);
631 #ifdef ENABLE_IPV6 634 #ifdef ENABLE_IPV6
632 if (hp) 635 if (hp)
633 freehostent(hp); 636 freehostent(hp);
634 #endif 637 #endif
635 /* bad: */ 638 /* bad: */
636 *res = NULL; 639 *res = NULL;
637 return error; 640 return error;
638 } 641 }
OLDNEW
« no previous file with comments | « Modules/_freeze_importlib.c ('k') | Modules/getnameinfo.c » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+