You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Also, because it's a public API, if call this API directly like this:
use triple_accel;fnmain(){let len:usize = 10830581488692310795;let _ = triple_accel::alloc_str(len);}
The output is as follows:
---- test_alloc_str_jsItp stdout ----
len = 10830581488692310795
thread 'test_alloc_str_jsItp' panicked at library/alloc/src/raw_vec.rs:25:5:
capacity overflow
stack backtrace:
0: rust_begin_unwind
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/std/src/panicking.rs:652:5
1: core::panicking::panic_fmt
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/core/src/panicking.rs:72:14
2: alloc::raw_vec::capacity_overflow
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/alloc/src/raw_vec.rs:25:5
3: alloc::raw_vec::handle_error
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/alloc/src/raw_vec.rs:593:29
4: alloc::raw_vec::RawVec<T,A>::with_capacity_zeroed_in
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/alloc/src/raw_vec.rs:178:25
5: <T as alloc::vec::spec_from_elem::SpecFromElem>::from_elem
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/alloc/src/vec/spec_from_elem.rs:25:31
6: alloc::vec::from_elem
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/alloc/src/vec/mod.rs:2739:5
7: triple_accel::alloc_str
at ./src/lib.rs:199:17
8: triple_accel::test_alloc_str_jsItp
at ./src/lib.rs:262:13
9: triple_accel::test_alloc_str_jsItp::{{closure}}
at ./src/lib.rs:247:26
10: core::ops::function::FnOnce::call_once
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/core/src/ops/function.rs:250:5
11: core::ops::function::FnOnce::call_once
at /rustc/d84b9037541f45dc2c52a41d723265af211c0497/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
The text was updated successfully, but these errors were encountered:
Hi, I'm developing a fuzzer to test the safe abstraction, and I fonnd a segmentation fault when calling function
src/lib/alloc_str()
.This is a test case:
Also, because it's a public API, if call this API directly like this:
The output is as follows:
The text was updated successfully, but these errors were encountered: