Lines 1679-1687
http_request(struct url *URL, const char *op, stru
Link Here
|
1679 |
else |
1679 |
else |
1680 |
http_cmd(conn, "Referer: %s", p); |
1680 |
http_cmd(conn, "Referer: %s", p); |
1681 |
} |
1681 |
} |
1682 |
if ((p = getenv("HTTP_USER_AGENT")) != NULL && *p != '\0') |
1682 |
if ((p = getenv("HTTP_USER_AGENT")) != NULL) { |
1683 |
http_cmd(conn, "User-Agent: %s", p); |
1683 |
if (*p != '\0') |
1684 |
else |
1684 |
http_cmd(conn, "User-Agent: %s", p); |
|
|
1685 |
} else |
1685 |
http_cmd(conn, "User-Agent: %s " _LIBFETCH_VER, getprogname()); |
1686 |
http_cmd(conn, "User-Agent: %s " _LIBFETCH_VER, getprogname()); |
1686 |
if (url->offset > 0) |
1687 |
if (url->offset > 0) |
1687 |
http_cmd(conn, "Range: bytes=%lld-", (long long)url->offset); |
1688 |
http_cmd(conn, "Range: bytes=%lld-", (long long)url->offset); |