A number of places were trying to decode the result of wait(). Add a simple
utility function that does that and a struct that encapsulates the
decoded result. Then also provide a pretty-printer for that class.
Details
Details
- Reviewers
zturner krytarowski eugene - Commits
- rG3508fc8cc518: Add pretty-printer for wait(2) statuses and modernize the code handling them
rLLDB305689: Add pretty-printer for wait(2) statuses and modernize the code handling them
rL305689: Add pretty-printer for wait(2) statuses and modernize the code handling them
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
source/Host/common/Host.cpp | ||
---|---|---|
1001 ↗ | (On Diff #101758) | WIFCONTINUED()? |
source/Host/common/Host.cpp | ||
---|---|---|
1001 ↗ | (On Diff #101758) | I'm deliberately ignoring that, as we don't have a use for it yet. On linux you have to pass the a special flag to waitpid to receive those notifications, and we don't do that. Does it work the same way on netbsd? If it possible to get those during normal interaction (without WCONTINUED), then I need to add it (and probably netbsd code needs to handle it), but otherwise I propose to skip it for the time being. |
source/Host/common/Host.cpp | ||
---|---|---|
1001 ↗ | (On Diff #101758) | I see, we need WCONTINUED too. We can skip it now. |
source/Host/common/Host.cpp | ||
---|---|---|
1010 ↗ | (On Diff #101759) | I wouldn't call it a hack. :) More like data-oriented programming... :P But I don't care about it too much. |