Re: [PATCH 10/10] Enable SHA-256 by default in breaking changes mode

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

 



On 2025-06-20 at 14:58:07, Junio C Hamano wrote:
> "brian m. carlson" <sandals@xxxxxxxxxxxxxxxxxxxx> writes:
> > Signed-off-by: brian m. carlson <sandals@xxxxxxxxxxxxxxxxxxxx>
> > ---
> >  hash.h        | 6 ++++++
> >  t/test-lib.sh | 7 ++++++-
> >  2 files changed, 12 insertions(+), 1 deletion(-)
> >
> > diff --git a/hash.h b/hash.h
> > index 0e14cade4e..144b53b7d6 100644
> > --- a/hash.h
> > +++ b/hash.h
> > @@ -174,8 +174,14 @@ static inline void git_SHA256_Clone(git_SHA256_CTX *dst, const git_SHA256_CTX *s
> >  #define GIT_HASH_SHA256 2
> >  /* Number of algorithms supported (including unknown). */
> >  #define GIT_HASH_NALGOS (GIT_HASH_SHA256 + 1)
> > +
> >  /* Default hash algorithm if unspecified. */
> > +#ifdef WITH_BREAKING_CHANGES
> > +#define GIT_HASH_DEFAULT GIT_HASH_SHA256
> > +#else
> >  #define GIT_HASH_DEFAULT GIT_HASH_SHA1
> > +#endif
> 
> I think we decided to format the above this way.
> 
>     #ifdef WITH_BREAKING_CHANGES
>     # define GIT_HASH_DEFAULT GIT_HASH_SHA256
>     #else
>     # define GIT_HASH_DEFAULT GIT_HASH_SHA1
>     #endif

Great, I'll put this in a v2.
-- 
brian m. carlson (they/them)
Toronto, Ontario, CA

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux