From 2dbaaf92e577fb5bb65c534a4b69f1af5dee46f1 Mon Sep 17 00:00:00 2001 From: Momtchil Momtchev Date: Sat, 17 Oct 2020 19:38:35 +0200 Subject: [PATCH] http2: remove unsupported %.* specifier The debug sprintf doesn't support %.* specifiers Fixes: https://github.com/nodejs/node/issues/35688 PR-URL: https://github.com/nodejs/node/pull/35694 Reviewed-By: Anna Henningsen Reviewed-By: Franziska Hinkelmann Reviewed-By: Rich Trott Reviewed-By: Ricky Zhou <0x19951125@gmail.com> Reviewed-By: David Carlier --- src/node_http2.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node_http2.cc b/src/node_http2.cc index f4f8eeb17c6ebf..fc345e52b23e2e 100644 --- a/src/node_http2.cc +++ b/src/node_http2.cc @@ -1136,7 +1136,7 @@ int Http2Session::OnNghttpError(nghttp2_session* handle, // Unfortunately, this is currently the only way for us to know if // the session errored because the peer is not an http2 peer. Http2Session* session = static_cast(user_data); - Debug(session, "Error '%.*s'", len, message); + Debug(session, "Error '%s'", message); if (strncmp(message, BAD_PEER_MESSAGE, len) == 0) { Environment* env = session->env(); Isolate* isolate = env->isolate();