Hi,

On Mon, Nov 16, 2015 at 09:48:09PM -0500, Selva Nair wrote:
> v2 changes
>  - cleaner, hopefully easier to get a code review :)
>  - handles both console mode and service mode
> -- >8 --
> 
> Handle ctrl-C or ctrl-Break sent to the console as a SIGTERM.
> Depending on the console mode, windows delivers ctrl-C as a
> keyboard input or as a signal. We handle both cases. This allows
> graceful termination of openvpn from programs such as nssm.
> Works in both console mode and service mode.

If I read this right, the new code uses WriteConsoleInput() only to
signal "hey, some work to do here, wake up!" without actually sending any
keypress-to-itself, and the signal itself is sent by throw_signal()?

This is certainly nicer :-)

(Is it actually quicker as well, so does the nssm timeout still need to
be adjusted?  Haven't seen feedback from Samuli here yet)

gert

-- 
USENET is *not* the non-clickable part of WWW!
                                                           //www.muc.de/~gert/
Gert Doering - Munich, Germany                             g...@greenie.muc.de
fax: +49-89-35655025                        g...@net.informatik.tu-muenchen.de

Attachment: signature.asc
Description: PGP signature

Reply via email to