/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to mandos-monitor

  • Committer: Teddy Hogeborn
  • Date: 2019-08-24 15:33:58 UTC
  • Revision ID: teddy@recompile.se-20190824153358-o69zprg8yiub1t0d
mandos-monitor: Use new GLib.io_add_watch() call signature

* mandos-monitor: When calling GLib.io_add_watch(), always pass a
                  channel as the first argument instead of a file
                  descriptor, and pass priority as the second
                  argument.  This is supported by PyGObject 3.8 or
                  later.

Show diffs side-by-side

added added

removed removed

Lines of Context:
59
59
domain = 'se.recompile'
60
60
server_interface = domain + '.Mandos'
61
61
client_interface = domain + '.Mandos.Client'
62
 
version = "1.8.4"
 
62
version = "1.8.8"
63
63
 
64
64
try:
65
65
    dbus.OBJECT_MANAGER_IFACE
628
628
                            path=path)
629
629
 
630
630
        self.refresh()
631
 
        self._input_callback_tag = (GLib.io_add_watch
632
 
                                    (sys.stdin.fileno(),
633
 
                                     GLib.IO_IN,
634
 
                                     self.process_input))
 
631
        self._input_callback_tag = (
 
632
            GLib.io_add_watch(
 
633
                GLib.IOChannel.unix_new(sys.stdin.fileno()),
 
634
                GLib.PRIORITY_DEFAULT, GLib.IO_IN,
 
635
                self.process_input))
635
636
        self.main_loop.run()
636
637
        # Main loop has finished, we should close everything now
637
638
        GLib.source_remove(self._input_callback_tag)