This is an archive of the discontinued LLVM Phabricator instance.

[msan] Check sigset_t and sigaction arguments.
ClosedPublic

Authored by eugenis on Aug 31 2017, 6:26 PM.

Details

Summary

Check sigset_t arguments in ppoll, sig*wait*, sigprocmask
interceptors, and the entire "struct sigaction" in sigaction. This
can be done because sigemptyset/sigfullset are intercepted and
signal masks should be correctly marked as initialized.

Diff Detail

Repository
rL LLVM

Event Timeline

eugenis created this revision.Aug 31 2017, 6:26 PM
vitalybuka added inline comments.Aug 31 2017, 6:31 PM
compiler-rt/lib/msan/msan_interceptors.cc
137 ↗(On Diff #113498)

separate patch?

compiler-rt/test/msan/Linux/poll.cc
19 ↗(On Diff #113498)

maybe runtime args to avoid recompilation?

vitalybuka accepted this revision.Aug 31 2017, 6:51 PM
This revision is now accepted and ready to land.Aug 31 2017, 6:51 PM
eugenis updated this revision to Diff 113629.Sep 1 2017, 5:34 PM

addressed vitaly's comments

eugenis marked 2 inline comments as done.Sep 1 2017, 5:35 PM
eugenis updated this revision to Diff 113910.Sep 5 2017, 2:09 PM

fix sa_handler / sa_sigaction mix-up

This revision was automatically updated to reflect the committed changes.