mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2024-10-26 12:25:09 +03:00
small enhancement to last fix, pointed out by Alex Cornejo
* nanohttp.c: small enhancement to last fix, pointed out by Alex Cornejo svn path=/trunk/; revision=3617
This commit is contained in:
parent
d2f682a495
commit
e882765aa4
@ -1,3 +1,8 @@
|
||||
Tue May 15 22:18:08 PDT 2007 William Brack <wbrack@mmm.com.hk>
|
||||
|
||||
* nanohttp.c: small enhancement to last fix, pointed out
|
||||
by Alex Cornejo
|
||||
|
||||
Tue May 15 12:38:38 PDT 2007 William Brack <wbrack@mmm.com.hk>
|
||||
|
||||
* nanohttp.c: fixed problem on gzip streams (bug #438045)
|
||||
|
@ -1203,8 +1203,10 @@ xmlNanoHTTPRead(void *ctx, void *dest, int len) {
|
||||
|
||||
ctxt->strm->next_out = dest;
|
||||
ctxt->strm->avail_out = len;
|
||||
ctxt->strm->avail_in = ctxt->inptr - ctxt->inrptr;
|
||||
|
||||
while (ctxt->strm->avail_out > 0 && xmlNanoHTTPRecv(ctxt) > 0) {
|
||||
while (ctxt->strm->avail_out > 0 &&
|
||||
(ctxt->strm->avail_in > 0 || xmlNanoHTTPRecv(ctxt) > 0)) {
|
||||
orig_avail_in = ctxt->strm->avail_in =
|
||||
ctxt->inptr - ctxt->inrptr - bytes_read;
|
||||
ctxt->strm->next_in = BAD_CAST (ctxt->inrptr + bytes_read);
|
||||
@ -1216,7 +1218,6 @@ xmlNanoHTTPRead(void *ctx, void *dest, int len) {
|
||||
}
|
||||
|
||||
ctxt->inrptr += bytes_read;
|
||||
ctxt->strm->avail_in = ctxt->inptr - ctxt->inrptr;
|
||||
return(len - ctxt->strm->avail_out);
|
||||
}
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user