X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=blobdiff_plain;f=src%2Finternal%2Fshgetc.c;h=e878b00ad50ac709b33366f11619817c1e535636;hp=96f72b6ab476fb65b14ca54db460241ece857ecb;hb=c20804500deebaabc56f383d48dd1ac77dce8349;hpb=a494171a5a2778fc7b4d24d673d950f3e9864063 diff --git a/src/internal/shgetc.c b/src/internal/shgetc.c index 96f72b6a..e878b00a 100644 --- a/src/internal/shgetc.c +++ b/src/internal/shgetc.c @@ -22,5 +22,6 @@ int __shgetc(FILE *f) else f->shend = f->rend; if (f->rend) f->shcnt += f->rend - f->rpos + 1; + if (f->rpos[-1] != c) f->rpos[-1] = c; return c; }