From: Adrian S. <a3s...@us...> - 2005-05-09 16:24:27
|
Update of /cvsroot/sblim/sfcb In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16789 Modified Files: httpAdapter.c Log Message: Fixed [ 1193800 ] sfcb doesn't honor the HTTP expect header sfcb now closes request with a 417 return code. Index: httpAdapter.c =================================================================== RCS file: /cvsroot/sblim/sfcb/httpAdapter.c,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- httpAdapter.c 26 Apr 2005 21:58:47 -0000 1.7 +++ httpAdapter.c 9 May 2005 16:24:18 -0000 1.8 @@ -643,12 +643,15 @@ cp += strspn(cp, " \t"); inBuf.useragent = cp; } - else if (strncasecmp(hdr, "TE:", 18) == 0) { - char *cp = &hdr[18]; + else if (strncasecmp(hdr, "TE:", 3) == 0) { + char *cp = &hdr[3]; cp += strspn(cp, " \t"); if (strncasecmp(cp,"trailers",8)==0) inBuf.trailers=1; } + else if (strncasecmp(hdr, "Expect:", 7) == 0) { + genError(conn_fd, &inBuf, 417, "Expectation Failed", NULL); //more); + } } if (doBa) { |