diff options
| author | bors <bors@rust-lang.org> | 2025-05-19 12:59:31 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2025-05-19 12:59:31 +0000 |
| commit | e5a2a6a15d05a4d4aad43f399dbe4242e0b2226d (patch) | |
| tree | e76b5510ef414f58f00275b49bcd269421fcd6c2 /compiler/rustc_session/src/filesearch.rs | |
| parent | 7068c8bd81c73db264c544f75a43158555567848 (diff) | |
| parent | 315874c077c9bd667306d3133a07f093dd113d70 (diff) | |
| download | rust-e5a2a6a15d05a4d4aad43f399dbe4242e0b2226d.tar.gz rust-e5a2a6a15d05a4d4aad43f399dbe4242e0b2226d.zip | |
Auto merge of #141243 - Zalathar:rollup-x5xt80l, r=Zalathar
Rollup of 5 pull requests Successful merges: - #140847 (coverage: Detect unused local file IDs to avoid an LLVM assertion) - #141117 (opt-dist: fix deprecated BOLT -icf=1 option) - #141225 (more ice tests) - #141239 (dladdr cannot leave dli_fname to be null) - #141242 (in `tests/ui/asm/aarch64/parse-error.rs`, only test cases specific to that target) r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_session/src/filesearch.rs')
| -rw-r--r-- | compiler/rustc_session/src/filesearch.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/rustc_session/src/filesearch.rs b/compiler/rustc_session/src/filesearch.rs index 207ba5157bd..cb3e9c80a13 100644 --- a/compiler/rustc_session/src/filesearch.rs +++ b/compiler/rustc_session/src/filesearch.rs @@ -82,9 +82,7 @@ fn current_dll_path() -> Result<PathBuf, String> { let fname_ptr = info.dli_fname.as_ptr(); #[cfg(not(target_os = "cygwin"))] let fname_ptr = { - if info.dli_fname.is_null() { - return Err("dladdr returned null pointer".into()); - } + assert!(!info.dli_fname.is_null(), "the docs do not allow dladdr to be null"); info.dli_fname }; let bytes = CStr::from_ptr(fname_ptr).to_bytes(); |
