]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #24478 - alexcrichton:issue-24313, r=aturon
authorbors <bors@rust-lang.org>
Tue, 28 Apr 2015 00:44:56 +0000 (00:44 +0000)
committerbors <bors@rust-lang.org>
Tue, 28 Apr 2015 00:44:56 +0000 (00:44 +0000)
Inspecting the current thread's info may not always work due to the TLS value
having been destroyed (or is actively being destroyed). The code for printing
a panic message assumed, however, that it could acquire the thread's name
through this method.

Instead this commit propagates the `Option` outwards to allow the
`std::panicking` module to handle the case where the current thread isn't
present.

While it solves the immediate issue of #24313, there is still another underlying
issue of panicking destructors in thread locals will abort the process.

Closes #24313


Trivial merge