Skip to content

Commit 258e30b

Browse files
committed
Add fallthrough comments
1 parent 0f91e2a commit 258e30b

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

ext/openssl/ossl_pkey_ec.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ static VALUE ossl_ec_key_set_private_key(VALUE self, VALUE private_key)
288288
case 0:
289289
if (bn == NULL)
290290
break;
291+
/* fallthrough */
291292
default:
292293
ossl_raise(eECError, "EC_KEY_set_private_key");
293294
}
@@ -334,6 +335,7 @@ static VALUE ossl_ec_key_set_public_key(VALUE self, VALUE public_key)
334335
case 0:
335336
if (point == NULL)
336337
break;
338+
/* fallthrough */
337339
default:
338340
ossl_raise(eECError, "EC_KEY_set_public_key");
339341
}

ext/openssl/ossl_ssl.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1621,6 +1621,7 @@ ossl_start_ssl(VALUE self, int (*func)(), const char *funcname, VALUE opts)
16211621
err_msg, verify_msg);
16221622
}
16231623
#endif
1624+
/* fallthrough */
16241625
default:
16251626
ossl_raise(eSSLError, "%s returned=%d errno=%d peeraddr=%"PRIsVALUE" state=%s",
16261627
funcname, ret2, errno, peeraddr_ip_str(self), SSL_state_string_long(ssl));
@@ -1905,6 +1906,7 @@ ossl_ssl_write_internal(VALUE self, VALUE str, VALUE opts)
19051906
continue;
19061907
#endif
19071908
if (errno) rb_sys_fail(0);
1909+
/* fallthrough */
19081910
default:
19091911
ossl_raise(eSSLError, "SSL_write");
19101912
}

0 commit comments

Comments
 (0)