-
Notifications
You must be signed in to change notification settings - Fork 689
Expose termination signal option in clone #343
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I would prefer to change the signature of clone to take two parameters, which we then combine in the function. This way we can have our cake and eat it too :) Thank you for reporting the issue. |
@fiveop, well, in the docs there are variable argument list for the Maybe some another type, like |
Our wrapper does not pass any additional arguments currently. And even if we did, I would prefer not to create a type for that. However, documentation for our wrapper would certainly help. Lamentably, this holds for pretty much all of nix-rust. |
Sure. I mean if I see |
DO NOT MERGE: proof of concept for comment Fixes nix-rust#343
On #348, we came to the conclusion that directly following libc's
|
In terms of "maximal Rustiness", at least for matching the APIs in libstd, I think something like this would work:
This would get used like this:
|
NB I don't think this fits in our current API style, but does fit a vision that @carllerche for either base nix or a higher level crate on top. |
Well, I don't think we should make it so complex. From #348 it looks like most people are comfortable with a separate argument. I think we should do it and move on. |
Which I implemented in my #344. |
Allow to specify signal when calling clone. This is my suggestion on how to fix #343.
I'm talking about this commit:
53cae89
The issue is that according to a man page you need to mix a signal name to a flags in clone function, like this:
But with bitflags you can't do it. E.g.
CloneFlags::from_bits(SIGCHLD)
returnsNone
.Any good idea how to fix it? Revert the commit?
The text was updated successfully, but these errors were encountered: