Dolda2000 GitWeb
/
ashd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5fc1bf9
)
Fixed a passdata bug in htparser.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Wed, 7 Jan 2009 05:15:37 +0000
(06:15 +0100)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Wed, 7 Jan 2009 05:15:37 +0000
(06:15 +0100)
src/htparser.c
patch
|
blob
|
blame
|
history
diff --git
a/src/htparser.c
b/src/htparser.c
index
68a3300
..
cec52dc
100644
(file)
--- a/
src/htparser.c
+++ b/
src/htparser.c
@@
-213,10
+213,10
@@
static off_t passdata(FILE *in, FILE *out, off_t max)
char buf[8192];
total = 0;
- while(!feof(in)) {
+ while(!feof(in)
&& (total < max)
) {
read = sizeof(buf);
if(max >= 0)
- read = m
ax
(max - total, read);
+ read = m
in
(max - total, read);
read = fread(buf, 1, read, in);
if(ferror(in))
return(-1);