]> sjero.net Git - wget/blobdiff - src/cookies.c
[svn] Rename long_to_string to number_to_string, and make it return a useful
[wget] / src / cookies.c
index d4ccb90ac8221a0409efdd3e356a438c3661570c..411160ee8f27aef775941efc3f2604a206512c5a 100644 (file)
@@ -121,7 +121,7 @@ delete_cookie (struct cookie *cookie)
   result = alloca (HP_len + 1 + numdigit (port) + 1);  \
   memcpy (result, host, HP_len);                       \
   result[HP_len] = ':';                                        \
-  long_to_string (result + HP_len + 1, port);          \
+  number_to_string (result + HP_len + 1, port);                \
 } while (0)
 
 /* Find cookie chain that corresponds to DOMAIN (exact) and PORT.  */
@@ -726,9 +726,9 @@ check_domain_match (const char *cookie_domain, const char *host)
     {
       int dlen = strlen (cookie_domain);
       int hlen = strlen (host);
-      /* hostname.foobar.com                   */
-      /*             bar.com                   */
-      /*            ^ <-- must be '.' for host */
+      /* cookie host:    hostname.foobar.com */
+      /* desired domain:             bar.com */
+      /* '.' must be here in host-> ^        */
       if (hlen > dlen && host[hlen - dlen - 1] != '.')
        return 0;
     }
@@ -825,7 +825,7 @@ set_cookie_header_cb (const char *hdr, void *closure)
    SIZE matches are written; if more matches are present, return the
    number of chains that would have been written.  */
 
-int
+static int
 find_matching_chains (const char *host, int port,
                      struct cookie *store[], int size)
 {