* match (ie. a specific IP)
*/
- if (addr && stricmp(hostip, exclude_list + s) == 0)
+ if (addr && strnicmp(hostip, exclude_list + s, e - s) == 0)
return 0; /* IP/hostname excluded. do not use proxy. */
- if (stricmp(hostname, exclude_list + s) == 0)
+ if (strnicmp(hostname, exclude_list + s, e - s) == 0)
return 0; /* IP/hostname excluded. do not use proxy. */
}
return sk_namelookup(host, canonicalname);
}
-Socket platform_new_connection(SockAddr addr, char *hostname,
- int port, int privport,
- int oobinline, int nodelay, Plug plug,
- const Config *cfg);
-
Socket new_connection(SockAddr addr, char *hostname,
int port, int privport,
int oobinline, int nodelay, Plug plug,
char *proxy_canonical_name;
Socket sret;
- if ( (sret = platform_new_connection(addr, hostname, port, privport,
- oobinline, nodelay, plug, cfg)) )
+ if ((sret = platform_new_connection(addr, hostname, port, privport,
+ oobinline, nodelay, plug, cfg)) !=
+ NULL)
return sret;
ret = snew(struct Socket_proxy_tag);