X-Git-Url: https://git.distorted.org.uk/u/mdw/catacomb/blobdiff_plain/eb31b00e4098ffb93eaf574f70cdd108b6610080..4e66da02f19648ee1be862e67ba1d1fc5549fb7f:/key-flags.c diff --git a/key-flags.c b/key-flags.c index b225ba1..d80da4f 100644 --- a/key-flags.c +++ b/key-flags.c @@ -1,6 +1,6 @@ /* -*-c-*- * - * $Id: key-flags.c,v 1.3 2004/03/28 01:58:47 mdw Exp $ + * $Id: key-flags.c,v 1.4 2004/04/02 01:03:49 mdw Exp $ * * Reading and writing key flag strings * @@ -30,6 +30,9 @@ /*----- Revision history --------------------------------------------------* * * $Log: key-flags.c,v $ + * Revision 1.4 2004/04/02 01:03:49 mdw + * Miscellaneous constification. + * * Revision 1.3 2004/03/28 01:58:47 mdw * Generate, store and retreive elliptic curve keys. * @@ -66,7 +69,7 @@ typedef struct flagent { unsigned m; } flagent; -static flagent flagtab[] = { +static const flagent flagtab[] = { /* --- Encoding types --- */ @@ -116,7 +119,7 @@ int key_readflags(const char *p, char **pp, unsigned *ff, unsigned *mm) for (;;) { size_t sz = strcspn(p, ",:"); - flagent *e, *ee = 0; + const flagent *e, *ee = 0; /* --- Look up the string in the flags table --- */ @@ -170,7 +173,7 @@ int key_readflags(const char *p, char **pp, unsigned *ff, unsigned *mm) void key_writeflags(unsigned f, dstr *d) { int del = 0; - flagent *e; + const flagent *e; unsigned m = 0; for (e = flagtab; e->name; e++) {