This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libgloss/arm: monitor_stderr [PATCH]


On 8/5/05, Nick Clifton <nickc@redhat.com> wrote:
> Hi Shaun,
> 
> > 2005-08-04  Shaun Jackman  <sjackman@gmail.com>
> >
> >       * libgloss/syscalls.c (initialise_monitor_handles): Set
> >       monitor_stdout to the result of SWI_open(":tt", "a")
> >       instead of simply duplicating stdout.
> 
> Assuming that nobody from the kernel world has a problem with this, then
> I would have no problem recommending that Jeff accepts it - with one
> proviso however:
> 
> > +  block[0] = (int) ":tt";
> > +  block[2] = 3;     /* length of filename */
> > +  block[1] = 8;     /* mode "a" */
> > +  monitor_stderr = do_AngelSWI (AngelSWI_Reason_Open, (void *) block);
> 
> I think that you ought to add a comment to the code explaining the
> situation (ie opening the same file name with different modes in order
> to allow the kernel to choose whether to use one or two file
> descriptors).  Otherwise future programmers might come along and think
> that this is a bug.
> 
> Cheers
>    Nick

Will do. I suffered a hard drive crash recently (woe is me), but once
I get my development box up and running again, I'll get back to the
list with a patch. This might give a little time for the kernel folk
to speak up. Speaking of which, which kernels actually implement the
RDP/RDI SWI API? The only pseudo-kernel I know of is gdb.

Cheers,
Shaun


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]