summaryrefslogtreecommitdiffstats
path: root/crypto/asn1/bio_asn1.c
diff options
context:
space:
mode:
authorRich Salz <rsalz@openssl.org>2016-08-30 13:31:18 -0400
committerRich Salz <rsalz@openssl.org>2016-09-22 08:36:26 -0400
commitf3b3d7f0033080f86ede5a53e8af2fb313091b5a (patch)
treec3761c9e3503980b7a2933211424165adad3fa8d /crypto/asn1/bio_asn1.c
parent39c136cc53d7b6fafdd1a0b52c035fd24358e01c (diff)
Add -Wswitch-enum
Change code so when switching on an enumeration, have case's for all enumeration values. Reviewed-by: Andy Polyakov <appro@openssl.org>
Diffstat (limited to 'crypto/asn1/bio_asn1.c')
-rw-r--r--crypto/asn1/bio_asn1.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/asn1/bio_asn1.c b/crypto/asn1/bio_asn1.c
index 400effa12c..d3cc108ed3 100644
--- a/crypto/asn1/bio_asn1.c
+++ b/crypto/asn1/bio_asn1.c
@@ -157,7 +157,6 @@ static int asn1_bio_write(BIO *b, const char *in, int inl)
for (;;) {
switch (ctx->state) {
-
/* Setup prefix data, call it */
case ASN1_STATE_START:
if (!asn1_bio_setup_ex(b, ctx, ctx->prefix,
@@ -223,7 +222,8 @@ static int asn1_bio_write(BIO *b, const char *in, int inl)
break;
- default:
+ case ASN1_STATE_POST_COPY:
+ case ASN1_STATE_DONE:
BIO_clear_retry_flags(b);
return 0;