lemo created this revision.
Herald added a subscriber: ki.stfu.
1. Fix a data race (g_interrupt_sent flag usage was not thread safe, signals
can be handled on arbitrary threads)
2. exit() is not signal-safe, replaced it with the signal-safe equivalent
_exit()
https://reviews.llvm.org/D37926
F
zturner added a comment.
It turns out the function this called, `DispatchInputInterrupt`, already
acquires a mutex. Maybe put the synchronization in there? Then you don't have
to reproduce the synchronization in both MI and LLDB
https://reviews.llvm.org/D37926
clayborg added a comment.
Looks fine to me.
https://reviews.llvm.org/D37926
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rL313785: Fix the SIGINT handlers (authored by amccarth).
Changed prior to commit:
https://reviews.llvm.org/D37926?vs=115473&id=116035#toc
Repository:
rL LLVM
https://reviews.llvm.org/D37926
Files:
How would that fix look? If the intention is to ignore nested SIGINT then
doing it directly in the handler seems cleaner and safer (re. safety, note
that m_input_reader_stack.GetMutex() is a std::*recursive_*mutex so
depending on it in signal handlers is a big no-no. The recursive_mutex
looks like