Skip to content

Commit

Permalink
Fix handling of 'HTTP/1.1 100 Continue' response
Browse files Browse the repository at this point in the history
When we jump back to 'cont' it needs to fetch the next response line,
not just check the existing contents of the buffer (which will be an
empty line).

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
  • Loading branch information
David Woodhouse authored and David Woodhouse committed Jan 3, 2010
1 parent c3497a1 commit f900f63
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion http.c
Expand Up @@ -104,12 +104,12 @@ static int process_http_response(struct openconnect_info *vpninfo, int *result,
int http10 = 0, closeconn = 0;
int i;

cont:
if (openconnect_SSL_gets(vpninfo->https_ssl, buf, sizeof(buf)) < 0) {
vpninfo->progress(vpninfo, PRG_ERR, "Error fetching HTTPS response\n");
return -EINVAL;
}

cont:
if (!strncmp(buf, "HTTP/1.0 ", 9)) {
http10 = 1;
closeconn = 1;
Expand Down

0 comments on commit f900f63

Please sign in to comment.