[network-manager-openswan/nm-1-0] service: watch for pty master hangups



commit f516f6b5355d710c580da18574bcf07ff46dddf5
Author: Lubomir Rintel <lkundrak v3 sk>
Date:   Thu Oct 22 12:04:54 2015 +0200

    service: watch for pty master hangups
    
    The callback handles hangups, but they seem to be accidentally masked out.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1271973#c5
    (cherry picked from commit 984035deb4ce61ce5e65d5b05add1197e7fd5f2b)

 src/nm-openswan-service.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/nm-openswan-service.c b/src/nm-openswan-service.c
index 9b22545..182002b 100644
--- a/src/nm-openswan-service.c
+++ b/src/nm-openswan-service.c
@@ -1117,7 +1117,7 @@ connect_step (NMOpenSwanPlugin *self, GError **error)
                priv->channel = g_io_channel_unix_new (up_pty);
                g_io_channel_set_encoding (priv->channel, NULL, NULL);
                g_io_channel_set_buffered (priv->channel, FALSE);
-               priv->io_id = g_io_add_watch (priv->channel, G_IO_IN | G_IO_ERR, io_cb, self);
+               priv->io_id = g_io_add_watch (priv->channel, G_IO_IN | G_IO_ERR | G_IO_HUP, io_cb, self);
 
                if (debug) {
                        pipe_init (&priv->out, up_stdout, "OUT");


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