Age | Commit message (Collapse) | Author |
|
not setting the FILE bufread member to flag the end of the buffer.
Also, do not set bufgetc member if getc macro support is disabled.
|
|
|
|
|
|
to match that of current glibc; i.e. don't do anything and return success.
Apparently, php calls fflush() on a file opened as readonly before trying
to read. Eventually I'll add some config options to flag this and several
other instances of nonportable code.
|
|
back. Unfortunately, none of my test cases caught it.
|
|
%c, %s, and %[ specifiers. Note that scanf is undergoing rewrite so I
didn't bother optimizing this. I did run all my regression tests though.
Set EOF correctly for fmemopen on readonly streams. I really need to
check what glibc behavior is for the various open modes though.
|
|
is built without buffer support.
|
|
seeks to the end of the stream when append mode is set and we are
transitioning to write mode, so that subsequent ftell() return
values are correct.
Also fix _stdio_fopen to support fdopen() with append specified when
the underlying file didn't have O_APPEND set. It now sets the
O_APPEND flag as recommended by SUSv3 and is done by glibc.
|
|
|
|
Also added outdigit support and (legacy) YESSTR/NOSTR support.
|
|
instead of -1 as expected.
|
|
|
|
Hopefully locale support will build when cross compiling now. Collation is
still not supported, but that's what I'm currently working on. In the
next couple of days, I'll probably put up a couple of files for download
that will save people the trouble of generating all the glibc locales.
Added *wprintf functions, although they currently don't support floating
point. That will be fixed when I rewrite _dtostr... or possibly before.
Added the wcsto{inttype} functions.
Added iconv() and a mini iconv utility. The require locale support and
only provide for conversions involving the various unicode encodings
{ UCS-4*, UCS-2*, UTF-32*, UTF-16*, UTF-8 }, the 8-bit codesets built
with the locale data, and the internal WCHAR_T.
|
|
comment as an mjn3 only item.
|
|
Require printf format strings to be valid multibyte strings beginning and
ending in their initial shift state, as per the stds.
Fixed a bug in _wchar_wcsntoutf8s(). Don't store wcs position if dst is NULL.
Also, introduce an awful hack into _wchar_wcsntoutf8s() and wcsrtombs() in
order to support %ls in printf. See comments below for details.
Change behaviour of wc<->mb functions when in the C locale. Now they do
a 1-1 map for the range 0x80-UCHAR_MAX. This is for backwards compatibility
and consistency with the stds requirements that a printf format string by
a valid multibyte string beginning and ending in it's initial shift state.
|
|
floating point output, so at least implement that. But grouping will
have to wait for the rewrite of _dtostr.
|
|
when the grouping flag "'" is specified. Grouping for floating point values
may wait until I do a rewrite of the floating pt to string code...
|
|
been working on a new config system on and off for about 6 months
now, but I've never been fully satisfied. Well, I'm finally am
happy with the new config system, so here it is. This completely
removes the old uClibc configuration system, and replaces it with
an entirely new system based on LinuxKernelConf, from
http://www.xs4all.nl/~zippel/lc/
As it turns out, Linus has just merged LinuxKernelConf into Linux
2.5.45, so it looks like I made the right choice.
I have thus far updated only x86. I'll be updating the other
architectures shortly.
-Erik
|
|
-Erik
|
|
without custom stream support. In that case, it is necessary to do
a va_copy. Note: The affected code is not built in the stock config.
Also, make sure each va_copy has a matching va_end, as required by C99.
|
|
case.
|
|
the cookie pointer was set to NULL as a debugging aid. However,
some of the perl 5.8 test rely on being able to close stderr and
still try writing to it. So now, the cookie pointer and handler
function pointers are set to that it is a "normal" file with a
file descriptor of -1.
Note: The cookie pointer is reset to NULL if the FILE struct is
free'd by fclose.
|
|
sense to exclude it, gcc always supports long long, and we never
fully excluded long long anyways (off64_t for example).
-Erik
|
|
One involving %o and one involving %f.
|
|
I think they're fixed now (I've run a few tests).
Note: __fsetlocking() is not threadsafe... but glibc's doesn't appear to
be either.
|
|
needlessly. To do so increases the generated code size with bcc.
Eliminate duplicate define warnings in wstring.c.
Fix potentially broken preprocessor comparisons. The preprocessor
converts integers to maximal signed type, so inequality comparisons
involving UINTMAX_MAX, ULLONG_MAX, and (if no long long) ULONG_MAX
were potentially broken.
|
|
using
a 3.0.4 version of the sh-linux-gcc compiler.
|
|
This falls under undefined behavior wrt ANSI/ISO C99, but
SUSv3 seems to treat it as a no-op and it occurs in some apps.
Fixed a problem with _stdio_fwrite() not checking for underlying
write() failures.
Fixed both _stdio_fwrite() and _stdio_fread() to make sure that
the putc and getc macros were disabled if the stream was in
and error state.
The above changes should take care of a problem initially reported
by "Steven J. Hill" <sjhill@realitydiluted.com>.
|
|
|
|
iff we do not have vfork available, which is simpler and more reasonable.
-Erik
|
|
|
|
Implemented unformatted wide i/o functions. (ungetwc still needs testing)
Fix a few bugs in wchar.c.
Modifications for bcc/elks support.
|
|
standards. Temporarily added a utility function to wrap Erik's strerror_r
so that "Unknown error xxx" strings can be generated for errno's which
cause strerror_r to fail. That utility function will eventually be merged
in with the strerror/strerror_r functions when I change over to optionallly
mmap'ing the system error strings to provide for lower mem comsumption on
non-MMU platforms, as well as locale-specific system error messages.
|
|
The writer for the stream returned by open_memstream was supposed to
keep the buffer nul-terminated. I apparently left out a statement.
|
|
non-NULL terminated string problem that could result from the use
of open_memstream(). Manuel may have a better solution, but this
one works for me, since with this plus the popen fix I can now run
things like gdb properly. Thanks Rik!
|
|
There is a minor bug in the implementation of popen(). In the case
where the file descriptor returned from its call to pipe() is the same
as the file descriptor that it is meant to be (where the dup2() branch
is not taken), the end of the pipe is still closed by close(reading)
even though it shouldn't be.
Thanks Ted!
|
|
-Erik
|
|
port. Also, explicitly use the macro versions of isdigit and isspace in the
printf and scanf code.
|
|
|
|
auto-transition, we fail the operation. This is different than glibc's
apparent behavior for writing of clearing the read buffer and still
failing the write without setting the stream's error flag.
Also, change a number of "errno = xxx" assignments to use __set_errno().
Also, change setvbuf(file, NULL, _IO{LF}BF, 0) behavior to more closely
match glibc's by keeping the current buffer and only changing the buffering
mode. Update setlinebuf() in the process to match the man page behavior.
|
|
by Ilguiz Latypov <ilatypov@superbt.com>.
|
|
|
|
a separate header file for those, and fixup references.
-Erik
|
|
which is needed for busybox ash when using largefile support.
-Erik
|
|
-Erik
|
|
-Erik
|
|
|
|
I successfully managed to blow away all the modeflags for the file
_except_ the one dealing with buffering...
|
|
|
|
default static initiailization and forgotten to update _stdio_init().
|