summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2016-09-13 16:04:52 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2016-09-13 16:04:52 +0000
commitd31476be203112a975b093e00645e456b5a5777f (patch)
tree3811581470ca6ca18a695468b263115ee24a3705 /usr.sbin
parent5bffb3b51daf6ba806ab70c9c866bf1c0808f598 (diff)
Inconsistant use of case (value): idiom drives me nuts, I have no idea
what purpose it was intended to serve.
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/acme-client/acctproc.c6
-rw-r--r--usr.sbin/acme-client/json.c10
-rw-r--r--usr.sbin/acme-client/main.c30
3 files changed, 23 insertions, 23 deletions
diff --git a/usr.sbin/acme-client/acctproc.c b/usr.sbin/acme-client/acctproc.c
index d17a645b363..eb2da4482e5 100644
--- a/usr.sbin/acme-client/acctproc.c
+++ b/usr.sbin/acme-client/acctproc.c
@@ -1,4 +1,4 @@
-/* $Id: acctproc.c,v 1.6 2016/09/13 16:01:37 deraadt Exp $ */
+/* $Id: acctproc.c,v 1.7 2016/09/13 16:04:51 deraadt Exp $ */
/*
* Copyright (c) 2016 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -391,12 +391,12 @@ acctproc(int netsock, const char *acctkey, int newacct)
break;
switch (op) {
- case (ACCT_SIGN):
+ case ACCT_SIGN:
if (op_sign(netsock, pkey))
break;
warnx("op_sign");
goto out;
- case (ACCT_THUMBPRINT):
+ case ACCT_THUMBPRINT:
if (op_thumbprint(netsock, pkey))
break;
warnx("op_thumbprint");
diff --git a/usr.sbin/acme-client/json.c b/usr.sbin/acme-client/json.c
index da98bd69b2f..1cf68a6e84a 100644
--- a/usr.sbin/acme-client/json.c
+++ b/usr.sbin/acme-client/json.c
@@ -1,4 +1,4 @@
-/* $Id: json.c,v 1.3 2016/09/01 00:35:22 florian Exp $ */
+/* $Id: json.c,v 1.4 2016/09/13 16:04:51 deraadt Exp $ */
/*
* Copyright (c) 2016 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -84,9 +84,9 @@ build(struct parse *parse, struct jsmnn **np,
n->type = t->type;
switch (t->type) {
- case (JSMN_STRING):
+ case JSMN_STRING:
/* FALLTHROUGH */
- case (JSMN_PRIMITIVE):
+ case JSMN_PRIMITIVE:
n->fields = 1;
n->d.str = strndup
(js + t->start,
@@ -94,7 +94,7 @@ build(struct parse *parse, struct jsmnn **np,
if (NULL == n->d.str)
break;
return (1);
- case (JSMN_OBJECT):
+ case JSMN_OBJECT:
n->fields = t->size;
n->d.obj = calloc(n->fields,
sizeof(struct jsmnp));
@@ -117,7 +117,7 @@ build(struct parse *parse, struct jsmnn **np,
if (i < (size_t)t->size)
break;
return (j + 1);
- case (JSMN_ARRAY):
+ case JSMN_ARRAY:
n->fields = t->size;
n->d.array = calloc(n->fields,
sizeof(struct jsmnn *));
diff --git a/usr.sbin/acme-client/main.c b/usr.sbin/acme-client/main.c
index 1549ecc9ba4..44a8f4f408b 100644
--- a/usr.sbin/acme-client/main.c
+++ b/usr.sbin/acme-client/main.c
@@ -1,4 +1,4 @@
-/* $Id: main.c,v 1.10 2016/09/01 13:47:54 florian Exp $ */
+/* $Id: main.c,v 1.11 2016/09/13 16:04:51 deraadt Exp $ */
/*
* Copyright (c) 2016 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -103,48 +103,48 @@ main(int argc, char *argv[])
while (-1 != (c = getopt(argc, argv, "bFmnNrs:tva:f:c:C:k:")))
switch (c) {
- case ('a'):
+ case 'a':
agreement = optarg;
break;
- case ('b'):
+ case 'b':
backup = 1;
break;
- case ('c'):
+ case 'c':
free(certdir);
if (NULL == (certdir = strdup(optarg)))
err(EXIT_FAILURE, "strdup");
break;
- case ('C'):
+ case 'C':
free(chngdir);
if (NULL == (chngdir = strdup(optarg)))
err(EXIT_FAILURE, "strdup");
break;
- case ('f'):
+ case 'f':
free(acctkey);
if (NULL == (acctkey = strdup(optarg)))
err(EXIT_FAILURE, "strdup");
break;
- case ('F'):
+ case 'F':
force = 1;
break;
- case ('k'):
+ case 'k':
free(keyfile);
if (NULL == (keyfile = strdup(optarg)))
err(EXIT_FAILURE, "strdup");
break;
- case ('m'):
+ case 'm':
multidir = 1;
break;
- case ('n'):
+ case 'n':
newacct = 1;
break;
- case ('N'):
+ case 'N':
newkey = 1;
break;
- case ('r'):
+ case 'r':
revocate = 1;
break;
- case ('s'):
+ case 's':
authority = -1;
for (i = 0; i < nitems(authorities); i++) {
if (strcmp(authorities[i].name, optarg) == 0) {
@@ -155,14 +155,14 @@ main(int argc, char *argv[])
if (-1 == authority)
errx(EXIT_FAILURE, "unknown acme authority");
break;
- case ('t'):
+ case 't':
/*
/ Undocumented feature.
* Don't use it.
*/
remote = 1;
break;
- case ('v'):
+ case 'v':
verbose = verbose ? 2 : 1;
break;
default: