Commit 72e63b91 authored by Niels Möller's avatar Niels Möller

* sexp2dsa.c (dsa_keypair_from_sexp_alist): Use a const pointer

array for the keywords.
(dsa_signature_from_sexp): Likewise.
* sexp2rsa.c (rsa_keypair_from_sexp_alist): Likewise.
(rsa_keypair_from_sexp): Likewise.

Rev: src/nettle/sexp2dsa.c:1.5
Rev: src/nettle/sexp2rsa.c:1.12
parent 64776de1
......@@ -54,7 +54,7 @@ dsa_keypair_from_sexp_alist(struct dsa_public_key *pub,
unsigned limit,
struct sexp_iterator *i)
{
static const uint8_t *names[5]
static const uint8_t * const names[5]
= { "p", "q", "g", "y", "x" };
struct sexp_iterator values[5];
unsigned nvalues = priv ? 5 : 4;
......@@ -91,7 +91,7 @@ int
dsa_signature_from_sexp(struct dsa_signature *rs,
struct sexp_iterator *i)
{
static const uint8_t *names[2] = { "r", "s" };
static const uint8_t * const names[2] = { "r", "s" };
struct sexp_iterator values[2];
if (!sexp_iterator_assoc(i, 2, names, values))
......
......@@ -54,7 +54,7 @@ rsa_keypair_from_sexp_alist(struct rsa_public_key *pub,
unsigned limit,
struct sexp_iterator *i)
{
static const uint8_t *names[8]
static const uint8_t * const names[8]
= { "n", "e", "d", "p", "q", "a", "b", "c" };
struct sexp_iterator values[8];
unsigned nvalues = priv ? 8 : 2;
......@@ -94,7 +94,7 @@ rsa_keypair_from_sexp(struct rsa_public_key *pub,
unsigned length, const uint8_t *expr)
{
struct sexp_iterator i;
static const uint8_t *names[3]
static const uint8_t * const names[3]
= { "rsa", "rsa-pkcs1", "rsa-pkcs1-sha1" };
if (!sexp_iterator_first(&i, length, expr))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment