Skip to content

Commit

Permalink
Don't panic across FFI
Browse files Browse the repository at this point in the history
Panicking across FFI was UB in older Rust versions and thus because of
MSRV it's safer to avoid it. This replaces the panic with print+abort on
`std` and double panic on no-std.

Closes #354
  • Loading branch information
Kixunil committed Jan 7, 2022
1 parent 6911734 commit 96ddf07
Show file tree
Hide file tree
Showing 3 changed files with 109 additions and 6 deletions.
4 changes: 3 additions & 1 deletion contrib/test.sh
84 changes: 81 additions & 3 deletions secp256k1-sys/src/lib.rs
27 changes: 25 additions & 2 deletions src/lib.rs

0 comments on commit 96ddf07

Please sign in to comment.