forked from torproject/tor
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rust: abort on panic in all profiles
Until rust-lang/rust#52652 is fixed, unwinding on panic is potentially unsound in a mixed C/Rust codebase. The codebase is supposed to be panic-free already, but just to be safe. This started mattering at commit d1820c1. Fixes #27199; bugfix on tor-0.3.3.1-alpha.
- Loading branch information
cypherpunks
committed
Aug 18, 2018
1 parent
87aacbf
commit fecd583
Showing
2 changed files
with
13 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
o Minor bugfixes (rust): | ||
- Abort on panic in all build profiles, instead of potentially unwinding | ||
into C code. Fixes bug 27199; bugfix on 0.3.3.1-alpha. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,17 @@ | ||
[workspace] | ||
members = ["tor_util", "protover", "smartlist", "external", "tor_allocate", "tor_rust"] | ||
|
||
# Can remove panic="abort" when this issue is fixed: | ||
# https://github.com/rust-lang/rust/issues/52652 | ||
[profile.dev] | ||
panic = "abort" | ||
|
||
[profile.release] | ||
debug = true | ||
panic = "abort" | ||
|
||
[profile.test] | ||
panic = "abort" | ||
|
||
[profile.bench] | ||
panic = "abort" |