[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#159633: strncpy on alpha/libc broken



On Sun, Sep 08, 2002 at 10:02:48PM -0400, Daniel Jacobowitz wrote:
>
> > OK, I see what you mean now.  However, there is still another SEGV
> > to fix.  The first jump to u_head could cause two loads even if you're
> > just copying one byte.
> 
> I think I forgot to CC you - did you see my followup patch?  It's not

I was referring to that patch in the previous message.  In the misaligned
case, the code will always do two 8-byte loads if the dest misalignment
is greater than the src misalignment even with your patch applied.
This will segfault when count == 1 and src is on a page boundary.

Another check needs to be added before the first branch to $u_head
to fix this.
-- 
Debian GNU/Linux 3.0 is out! ( http://www.debian.org/ )
Email:  Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt



Reply to: