mirror of
https://github.com/nghttp2/nghttp2.git
synced 2025-12-06 18:18:52 +08:00
fix: remove redundant sizeof check
Co-authored-by: Tatsuhiro Tsujikawa <404610+tatsuhiro-t@users.noreply.github.com>
This commit is contained in:
@@ -603,7 +603,7 @@ static int hd_ringbuf_init(nghttp2_hd_ringbuf *ringbuf, size_t bufsize,
|
||||
for (size = 1; size < bufsize; size <<= 1)
|
||||
;
|
||||
|
||||
if (size * sizeof(nghttp2_hd_entry *) > max_size) {
|
||||
if (size > max_size) {
|
||||
return NGHTTP2_ERR_NOMEM;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user