Ignore zero length domains in no_proxy.

This commit is contained in:
Giuseppe Scrivano 2010-05-25 18:36:02 +02:00
parent 475c452780
commit b2b76dcef4
2 changed files with 5 additions and 0 deletions

View File

@ -1,5 +1,7 @@
2010-05-25 Giuseppe Scrivano <gscrivano@gnu.org>
* host.c (sufmatch): Do not consider zero length entries.
* http.c (H_10X): New macro.
(gethttp): Silently ignore 1xx responses.

View File

@ -874,6 +874,9 @@ sufmatch (const char **list, const char *what)
lw = strlen (what);
for (i = 0; list[i]; i++)
{
if (list[i][0] == '\0')
continue;
for (j = strlen (list[i]), k = lw; j >= 0 && k >= 0; j--, k--)
if (c_tolower (list[i][j]) != c_tolower (what[k]))
break;