projects
/
oweals
/
musl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
48bb81a
)
fix incorrect initial count in shgetc when data is already buffered
author
Rich Felker
<dalias@aerifal.cx>
Wed, 11 Apr 2012 04:26:41 +0000
(
00:26
-0400)
committer
Rich Felker
<dalias@aerifal.cx>
Wed, 11 Apr 2012 04:26:41 +0000
(
00:26
-0400)
src/internal/shgetc.c
patch
|
blob
|
history
diff --git
a/src/internal/shgetc.c
b/src/internal/shgetc.c
index 7c4e58c1e7579effa325ef1e3c0ec5eabbed7fb5..82e3a4fa69152097e5c231edf8d4d8d1c82786f6 100644
(file)
--- a/
src/internal/shgetc.c
+++ b/
src/internal/shgetc.c
@@
-3,7
+3,7
@@
void __shlim(FILE *f, off_t lim)
{
f->shlim = lim;
- f->shcnt = f->rend
? f->rend - f->buf : 0
;
+ f->shcnt = f->rend
- f->rpos
;
if (lim && f->rend - f->rpos > lim)
f->shend = f->rpos + lim;
else