diff options
author | NIIBE Yutaka <gniibe@fsij.org> | 2022-01-04 14:06:54 +0900 |
---|---|---|
committer | NIIBE Yutaka <gniibe@fsij.org> | 2022-01-04 14:06:54 +0900 |
commit | f9ba07942b10c72af50bd73c92c4851b6981546e (patch) | |
tree | 988f95d30b6d44d58704f415e767cd69e8672908 /cipher/md5.c | |
parent | 034e4402dade7a4bcc239913b78c702c5c6f0dbb (diff) | |
download | libgcrypt-f9ba07942b10c72af50bd73c92c4851b6981546e.tar.gz |
cipher: Use const for *_spec_t, if possible.
* cipher/blake2.c: Use const.
* cipher/camellia-glue.c, cipher/cipher.c, cipher/crc.c: Likewise.
* cipher/des.c, cipher/gost28147.c, cipher/gostr3411-94.c: Likewise.
* cipher/keccak.c, cipher/mac-cmac.c, cipher/mac-gmac.c: Likewise.
* cipher/mac-hmac.c, cipher/mac-internal.h: Likewise.
* cipher/mac-poly1305.c, cipher/mac.c, cipher/md.c: Likewise.
* cipher/md.c, cipher/md2.c, cipher/md4.c, cipher/md5.c: Likewise.
* cipher/pubkey.c, cipher/rfc2268.c, cipher/rijndael.c: Likewise.
* cipher/rmd160.c, cipher/seed.c, cipher/serpent.c: Likewise.
* cipher/sha1.c, cipher/sha256.c, cipher/sha512.c: Likewise.
* cipher/sm3.c, cipher/sm4.c, cipher/stribog.c: Likewise.
* cipher/pubkey.c, cipher/rfc2268.c, cipher/rijndael.c: Likewise.
* src/cipher-proto.h, src/cipher.h: Likewise.
--
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'cipher/md5.c')
-rw-r--r-- | cipher/md5.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cipher/md5.c b/cipher/md5.c index e98aea52..5457fc38 100644 --- a/cipher/md5.c +++ b/cipher/md5.c @@ -299,11 +299,11 @@ md5_read( void *context ) return hd->bctx.buf; } -static byte asn[18] = /* Object ID is 1.2.840.113549.2.5 */ +static const byte asn[18] = /* Object ID is 1.2.840.113549.2.5 */ { 0x30, 0x20, 0x30, 0x0c, 0x06, 0x08, 0x2a, 0x86,0x48, 0x86, 0xf7, 0x0d, 0x02, 0x05, 0x05, 0x00, 0x04, 0x10 }; -static gcry_md_oid_spec_t oid_spec_md5[] = +static const gcry_md_oid_spec_t oid_spec_md5[] = { /* iso.member-body.us.rsadsi.pkcs.pkcs-1.4 (md5WithRSAEncryption) */ { "1.2.840.113549.1.1.4" }, @@ -312,7 +312,7 @@ static gcry_md_oid_spec_t oid_spec_md5[] = { NULL }, }; -gcry_md_spec_t _gcry_digest_spec_md5 = +const gcry_md_spec_t _gcry_digest_spec_md5 = { GCRY_MD_MD5, {0, 0}, "MD5", asn, DIM (asn), oid_spec_md5, 16, |