[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: sha512_process_bytes doesn't like odd sized buffers
From: |
J. Scott Edwards |
Subject: |
Re: sha512_process_bytes doesn't like odd sized buffers |
Date: |
Sat, 15 Mar 2008 09:10:24 -0600 |
Yes, my name and e-mail address look correct.
I assume that since it doesn't affect the coreutils, you won't be
releasing an updated version just for that? It is okay with me
because I have already checked my fix into the CVS for my project.
But I would like to update to the official release when it comes out.
Thanks
-Scott
On Sat, Mar 15, 2008 at 8:59 AM, Jim Meyering <address@hidden> wrote:
> Andreas Schwab <address@hidden> wrote:
> > Jim Meyering <address@hidden> writes:
> >
> >> The bug strikes whenever ctx->buflen|64 != 0.
> >
> > Btw, ctx->buflen|64 != 0 is always true because it is the same as
> > ctx->buflen|(64 != 0).
>
> Shameful ;-) I meant "ctx->buflen&64", of course.
>
>
> >> - sha256_process_block (ctx->buffer, ctx->buflen & ~63, ctx);
> >> -
> >> ctx->buflen &= 63;
> >> + sha256_process_block (ctx->buffer, ctx->buflen, ctx);
> >
> > I hope you are aware of that a & 63 is different from a & ~63?
>
> Of course. My mistake was in not *seeing* that "63 != ~63"
>
> Thanks. So I won't be making that latter change.
>