5391211824
* chore: bump node in DEPS to v16.15.0 * chore: update patches * src: allow preventing InitializeInspector in env https://github.com/nodejs/node/pull/35025 * chore: update node gn filenames * crypto: change default check(Host|Email) behavior * Revert "crypto: change default check(Host|Email) behavior" This reverts commit 1f1eb23702fe9dfc09470248d6c1a673f42b80fe. * update node crypto tests to work with boringssl Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
76 lines
3.2 KiB
Diff
76 lines
3.2 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Shelley Vohr <shelley.vohr@gmail.com>
|
|
Date: Mon, 11 Oct 2021 13:46:24 +0200
|
|
Subject: chore: fix -Wimplicit-fallthrough
|
|
|
|
Upstreamed at https://github.com/nghttp2/nghttp2/pull/1626.
|
|
|
|
diff --git a/deps/nghttp2/BUILD.gn b/deps/nghttp2/BUILD.gn
|
|
index 8bfecba74d4d90e9fbf0e2cd301118e4adc6cba8..63e1149f0c4a39cb944114e5824d6074343301e8 100644
|
|
--- a/deps/nghttp2/BUILD.gn
|
|
+++ b/deps/nghttp2/BUILD.gn
|
|
@@ -16,7 +16,6 @@ static_library("nghttp2") {
|
|
|
|
cflags_c = [
|
|
"-Wno-implicit-function-declaration",
|
|
- "-Wno-implicit-fallthrough",
|
|
"-Wno-string-plus-int",
|
|
"-Wno-unreachable-code-return",
|
|
"-Wno-unused-but-set-variable",
|
|
diff --git a/deps/nghttp2/lib/nghttp2_hd.c b/deps/nghttp2/lib/nghttp2_hd.c
|
|
index 30ee9b88920c0a0bb8f8b714e3deabe0207cac40..010edf48f614c23e971df0f37716275cc1656469 100644
|
|
--- a/deps/nghttp2/lib/nghttp2_hd.c
|
|
+++ b/deps/nghttp2/lib/nghttp2_hd.c
|
|
@@ -1892,7 +1892,7 @@ ssize_t nghttp2_hd_inflate_hd_nv(nghttp2_hd_inflater *inflater,
|
|
rv = NGHTTP2_ERR_HEADER_COMP;
|
|
goto fail;
|
|
}
|
|
- /* fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_HD_STATE_INFLATE_START:
|
|
case NGHTTP2_HD_STATE_OPCODE:
|
|
if ((*in & 0xe0u) == 0x20u) {
|
|
@@ -2002,7 +2002,7 @@ ssize_t nghttp2_hd_inflate_hd_nv(nghttp2_hd_inflater *inflater,
|
|
inflater->left = 0;
|
|
inflater->shift = 0;
|
|
DEBUGF("inflatehd: huffman encoded=%d\n", inflater->huffman_encoded != 0);
|
|
- /* Fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_HD_STATE_NEWNAME_READ_NAMELEN:
|
|
rfin = 0;
|
|
rv = hd_inflate_read_len(inflater, &rfin, in, last, 7, NGHTTP2_HD_MAX_NV);
|
|
@@ -2086,7 +2086,7 @@ ssize_t nghttp2_hd_inflate_hd_nv(nghttp2_hd_inflater *inflater,
|
|
inflater->left = 0;
|
|
inflater->shift = 0;
|
|
DEBUGF("inflatehd: huffman encoded=%d\n", inflater->huffman_encoded != 0);
|
|
- /* Fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_HD_STATE_READ_VALUELEN:
|
|
rfin = 0;
|
|
rv = hd_inflate_read_len(inflater, &rfin, in, last, 7, NGHTTP2_HD_MAX_NV);
|
|
diff --git a/deps/nghttp2/lib/nghttp2_session.c b/deps/nghttp2/lib/nghttp2_session.c
|
|
index 380a47c1b1e82b015c271e2818aed0baf982aa2d..2f3997709cd07f6f8294f985f60b2e1e4b85a2cf 100644
|
|
--- a/deps/nghttp2/lib/nghttp2_session.c
|
|
+++ b/deps/nghttp2/lib/nghttp2_session.c
|
|
@@ -2644,10 +2644,10 @@ static int session_after_frame_sent1(nghttp2_session *session) {
|
|
case NGHTTP2_HCAT_PUSH_RESPONSE:
|
|
stream->flags = (uint8_t)(stream->flags & ~NGHTTP2_STREAM_FLAG_PUSH);
|
|
++session->num_outgoing_streams;
|
|
- /* Fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_HCAT_RESPONSE:
|
|
stream->state = NGHTTP2_STREAM_OPENED;
|
|
- /* Fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_HCAT_HEADERS:
|
|
if (frame->hd.flags & NGHTTP2_FLAG_END_STREAM) {
|
|
nghttp2_stream_shutdown(stream, NGHTTP2_SHUT_WR);
|
|
@@ -5456,7 +5456,7 @@ ssize_t nghttp2_session_mem_recv(nghttp2_session *session, const uint8_t *in,
|
|
|
|
iframe->state = NGHTTP2_IB_READ_HEAD;
|
|
|
|
- /* Fall through */
|
|
+ __attribute__((fallthrough));
|
|
case NGHTTP2_IB_READ_HEAD: {
|
|
int on_begin_frame_called = 0;
|
|
|