From 80cd9d725f969f0217fa4626d4f281cb864f8cf3 Mon Sep 17 00:00:00 2001 From: Sukchan Lee Date: Thu, 14 Apr 2022 11:28:37 +0900 Subject: [PATCH] [SBI] fixed HTTP2 header values is 0 (#1488) --- lib/sbi/nghttp2-server.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/sbi/nghttp2-server.c b/lib/sbi/nghttp2-server.c index 5194f4811..999df08c4 100644 --- a/lib/sbi/nghttp2-server.c +++ b/lib/sbi/nghttp2-server.c @@ -858,7 +858,8 @@ static int on_header(nghttp2_session *session, const nghttp2_frame *frame, ogs_assert(value); valuebuf = nghttp2_rcbuf_get_buf(value); ogs_assert(valuebuf.base); - ogs_assert(valuebuf.len); + + if (valuebuf.len == 0) return 0; namestr = ogs_strndup((const char *)namebuf.base, namebuf.len); ogs_assert(namestr);