[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Libguestfs] [PATCH libnbd] api: New nbd_kill_command API for sending a signal to the command subprocess.



On 7/25/19 4:11 PM, Richard W.M. Jones wrote:
> On Thu, Jul 25, 2019 at 03:19:23PM -0500, Eric Blake wrote:
>> This looks a bit funny until I read the docs at [1].  When using
>> kill(2), I'm used to the function call 'kill(pid, 0)' probing for
>> process existence.  But on the command line, kill(1) has the behavior of
>> sending SIGTERM by default when you omit a signal number (and not
>> serving as a process existence probe).
> 
> The reason for this choice is that in some language bindings we might
> not have the SIG* symbols available, but there ought to still be a way
> to send a default.  Hopefully people will read the docs :-)

Your explanation is good enough for me :)

> 
> I pushed it with s/signal/signum/.
> 
> Are we waiting on any other ABI breaks or would now be a good time to
> do another 0.x release?

I know we've debated about a flag to nbd_shutdown to give the user more
control over whether to wait on in-flight commands to settle, but
without code for that, I don't see it stalling another 0.x release. In
the meantime, we've definitely broken API/ABI, so another release makes
it easier to test against.  Still, I'd appreciate a few minutes to post
my possible optimization of VALID|FREE in a few more spots, though.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]