This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
Re: [PATCH] Fix the spu specific strxfrm to match generic newlib and glibc
- From: Patrick Mansfield <patmans at us dot ibm dot com>
- To: Joel Schopp <jschopp at austin dot ibm dot com>
- Cc: newlib at sourceware dot org, Jeff Johnston <jjohnstn at redhat dot com>
- Date: Fri, 6 Apr 2007 08:58:42 -0700
- Subject: Re: [PATCH] Fix the spu specific strxfrm to match generic newlib and glibc
- References: <20070406150531.GA10658@us.ibm.com> <46166D5A.4010907@austin.ibm.com>
On Fri, Apr 06, 2007 at 10:55:06AM -0500, Joel Schopp wrote:
> This bug was originally caused by me and my misreading of the standard (to
> be fair the language is as clear as mud). This patch makes the behavior
> match what the standard intended, which is also the behavior of glibc. For
> correctness that should probably be my name in the changelog as I
> originally authored this patch.
OK. Jeff can you fix the attribution in the ChangeLog and apply?
Thanks ...
-- Patrick Mansfield
>
> -Joel
>
> Patrick Mansfield wrote:
> >Jeff - can you please apply this fix?
> >
> >Fix the spu specific strxfrm so that when the length of the src string is
> >greater than or equal to the passed in argument n we still copy over n
> >bytes.
> >
> >This matches the current glibc and the generic newlib strxfrm behaviour.
> >
> >newlib ChangeLog:
> >
> >2007-04-06 Patrick Mansfield <patmans@us.ibm.com>
> >
> > * libc/machine/spu/strxfrm.c: Fix strxfrm so we still copy data
> > even if the passed in length n is shorter than the source string.
> > This matches both the non-spu specific and the glibc strxfrm
> > behaviour.