=================================================================== RCS file: /home/cvspublic/httpd-2.0/modules/ssl/ssl_engine_io.c,v retrieving revision 1.100.2.15 retrieving revision 1.100.2.16 diff -u -r1.100.2.15 -r1.100.2.16 --- httpd-2.0/modules/ssl/ssl_engine_io.c 2004/08/23 14:59:52 1.100.2.15 +++ httpd-2.0/modules/ssl/ssl_engine_io.c 2004/08/27 09:03:24 1.100.2.16 @@ -562,8 +562,12 @@ *len = bytes; if (inctx->mode == AP_MODE_SPECULATIVE) { /* We want to rollback this read. */ - inctx->cbuf.value -= bytes; - inctx->cbuf.length += bytes; + if (inctx->cbuf.length > 0) { + inctx->cbuf.value -= bytes; + inctx->cbuf.length += bytes; + } else { + char_buffer_write(&inctx->cbuf, buf, (int)bytes); + } return APR_SUCCESS; } /* This could probably be *len == wanted, but be safe from stray