Benign repos Download

session.rs

Contains an unbounded block loopimports std::ffi::c_void
SHA-25637a022a96b74d236bb47b46f09a59ff19746dc2c9435b7ec11b2bc6da5fe6af4
MaleculeH(Db)Md(In)

Evidence

English function-word token "the" lines 1–6
1// Copyright 2018-2026 the Deno authors. MIT license.
2
3// On Windows MSVC, bindgen generates nghttp2 enum constants as i32 (C `int`),
4// while on Unix they are u32. Explicit `as` casts are needed for cross-platform
5// compatibility but trigger unnecessary_cast on the platform where the type
6// …
imports std::ffi::c_void lines 6–24
6:14… tches.
7#![allow(clippy::unnecessary_cast)]
8
9use std::cell::RefCell;
10use std::cell::UnsafeCell;
11use std::collections::HashMap;
12use std::ffi::c_void;
13use std::rc::Rc;
14
15use deno_core::OpState;
16use deno_core::cppgc;
17use deno_core::op2;
18use deno_core::serde_v8;
19use deno_core::v8;
20use libnghttp2 as ffi;
21use serde::Serialize;
22
23/// Type alias matching the C `ssize_t` type used by nghttp2 callbacks.
24/// On Unix, `ssize_t …
imports super::stream::Http2Headers lines 28–39
28:16… isize;
29#[cfg(windows)]
30type CSsizeT = i64;
31
32use super::stream::Http2Headers;
33use super::stream::Http2Priority;
34use super::stream::Http2Stream;
35use super::types::*;
36
37// Thread-local state buffers
38
39const SESSION_STATE_LEN: usize = SessionStateIndex::Count as u …
English function-word token "with" lines 69–76
69:51… -> Self {
70 let session_state = SESSION_STATE.with(|cell| {
71 // SAFETY: thread-local UnsafeCell, no concurrent access possible
72 let ptr = unsafe { (*cell.get()).as_mut_ptr() };
⋯4 lines
Contains an unbounded block loop lines 1574–1583
1574:12… stream = None;
1575 return;
1576 }
1577
1578 self.is_sending = true;
1579 loop {
1580 let mut src = std::ptr::null();
1581 let src_len =
1582 // SAFETY: self.session is a valid nghttp2 session pointer
1583 …

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.