This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
Re: [PATCH 4/5] stdio offloading
There are issues with this patch.
I'm happy to address them and resubmit later.
You have overridden vfprintf.c, but you have not overridden all of its
callers (e.g. sprintf.c and vasprintf.c are missing). This is necessary
because you do not have _r versions of routines that are used internally
elsewhere. For example, sprintf.c calls _sprintf_r which calls
_vfprintf_r which no longer exists. There may be other such _r calls
you have unchained by this override.
I had just today noticed sprintf, sscanf, and snprintf myself. Would have sent the patch
but didn't have time to test it yet. I'll check for others and add them as well before
resubmitting.
You have no errno support in your send_to_ppe function. The _r routines
are designed so as to make sure that errno is set properly for the
current reentrant structure. Is there an errno return code from your
standard calls that you can place into the reentrant struct?
I don't recall any way to get an errno, but I'll look into this some more.