Skip to content

Commit c4910dd

Browse files
committed
Add panic implementation for snpritnf
1 parent 0c14f66 commit c4910dd

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

rules/stdio/tgt_refcount.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,3 +94,13 @@ fn f9() -> Ptr<::std::fs::File> {
9494
fn f10() -> Ptr<::std::fs::File> {
9595
libcc2rs::cin()
9696
}
97+
98+
fn f21(a0: Ptr<u8>, a1: usize, a2: Ptr<u8>, va: &[VaArg]) -> i32 {
99+
panic!(
100+
"snprintf is not supported in the refcount model (buf_is_null={}, size={}, fmt={:?}, varargs={})",
101+
a0.is_null(),
102+
a1,
103+
a2.to_rust_string(),
104+
va.len()
105+
)
106+
}

0 commit comments

Comments
 (0)