This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
[PATCH] wrap #ifdef for C99 around iswspace and mbrtowc in vfscanf.c
- From: litb_devel at web dot de
- To: newlib at sources dot redhat dot com
- Date: Sat, 11 Oct 2008 12:20:07 +0200
- Subject: [PATCH] wrap #ifdef for C99 around iswspace and mbrtowc in vfscanf.c
Hello List,
while working on my port of newlib, i got undefined references to those
functions. That happened because i compile newlib using EL/IX level 1, which
causes them not to be defined.
I wrapped the portion that prints wide characters/strings with
_WANT_IO_C99_FORMATS, just like it's already done while parsing the format
string. Please be kind, it's my first patch/diff for newlib. :)
have fun, litb.
Index: libc/stdio/vfscanf.c
===================================================================
RCS file: /cvs/src/src/newlib/libc/stdio/vfscanf.c,v
retrieving revision 1.40
diff -r1.40 vfscanf.c
824a825
> #ifdef _WANT_IO_C99_FORMATS
863c864,866
< else if (flags & SUPPRESS)
---
> else
> #endif /* _WANT_IO_C99_FORMATS */
> if (flags & SUPPRESS)
952a956
> #ifdef _WANT_IO_C99_FORMATS
1001c1005,1007
< else if (flags & SUPPRESS)
---
> else
> #endif /* _WANT_IO_C99_FORMATS */
> if (flags & SUPPRESS)