diff options
author | ray <> | 2006-09-25 04:51:20 +0000 |
---|---|---|
committer | ray <> | 2006-09-25 04:51:20 +0000 |
commit | ef21d54c7ef3086090860a6d7fec498a4812e05f (patch) | |
tree | cbc97dc1f3a73f04cba4d983583335e7670c7532 /src | |
parent | 13a6567d19b818b40c2d187fe1ffedd4d405167e (diff) | |
download | openbsd-ef21d54c7ef3086090860a6d7fec498a4812e05f.tar.gz openbsd-ef21d54c7ef3086090860a6d7fec498a4812e05f.tar.bz2 openbsd-ef21d54c7ef3086090860a6d7fec498a4812e05f.zip |
Also accept "HTTP/1.1 200" as a success response.
OK djm@.
Diffstat (limited to 'src')
-rw-r--r-- | src/usr.bin/nc/socks.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/usr.bin/nc/socks.c b/src/usr.bin/nc/socks.c index daed99712e..da7bd0c60e 100644 --- a/src/usr.bin/nc/socks.c +++ b/src/usr.bin/nc/socks.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: socks.c,v 1.16 2006/01/25 23:21:37 djm Exp $ */ | 1 | /* $OpenBSD: socks.c,v 1.17 2006/09/25 04:51:20 ray Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 1999 Niklas Hallqvist. All rights reserved. | 4 | * Copyright (c) 1999 Niklas Hallqvist. All rights reserved. |
@@ -307,7 +307,8 @@ socks_connect(const char *host, const char *port, | |||
307 | } | 307 | } |
308 | close(proxyfd); | 308 | close(proxyfd); |
309 | goto again; | 309 | goto again; |
310 | } else if (strncmp(buf, "HTTP/1.0 200 ", 12) != 0) | 310 | } else if (strncmp(buf, "HTTP/1.0 200 ", 12) != 0 && |
311 | strncmp(buf, "HTTP/1.1 200 ", 12) != 0) | ||
311 | errx(1, "Proxy error: \"%s\"", buf); | 312 | errx(1, "Proxy error: \"%s\"", buf); |
312 | 313 | ||
313 | /* Headers continue until we hit an empty line */ | 314 | /* Headers continue until we hit an empty line */ |