X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fstdlib%2Fwcstod.c;h=0deb7010b1afa1f216b738b3ad128fbc3914ec1a;hb=f3ecdc1043f44468b2db794b259c5f66737f6f84;hp=03670b0bf03ce6682ba2d34220b4f5058f9f0e60;hpb=400c5e5c8307a2ebe44ef1f203f5a15669f20347;p=musl diff --git a/src/stdlib/wcstod.c b/src/stdlib/wcstod.c index 03670b0b..0deb7010 100644 --- a/src/stdlib/wcstod.c +++ b/src/stdlib/wcstod.c @@ -1,6 +1,8 @@ #include "shgetc.h" #include "floatscan.h" #include "stdio_impl.h" +#include +#include /* This read function heavily cheats. It knows: * (1) len will always be 1 @@ -31,8 +33,7 @@ static long double wcstox(const wchar_t *s, wchar_t **p, int prec) unsigned char buf[64]; FILE f = {0}; f.flags = 0; - f.rpos = f.rend = 0; - f.buf = buf + 4; + f.rpos = f.rend = f.buf = buf + 4; f.buf_size = sizeof buf - 4; f.lock = -1; f.read = do_read;