~ubuntu-branches/ubuntu/wily/sessioninstaller/wily-proposed

« back to all changes in this revision

Viewing changes to sessioninstaller/backends/synaptic.py

  • Committer: Package Import Robot
  • Author(s): Martin Pitt
  • Date: 2015-08-09 12:50:08 UTC
  • mto: This revision was merged to the branch mainline in revision 26.
  • Revision ID: package-import@ubuntu.com-20150809125008-yv3g067gk3k1drzo
Tags: upstream-0.20+bzr150
ImportĀ upstreamĀ versionĀ 0.20+bzr150

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/env python
2
1
# -*- coding: utf-8 -*-
3
2
"""Make use of synaptic as backend."""
4
3
# Copyright (C) 2008-2010 Sebastian Heinlein <devel@glatzor.de>
24
23
             "Michael Vogt <mvo@canonical.com"
25
24
 
26
25
import tempfile
27
 
from gettext import gettext as _
 
26
#from gettext import gettext as _
28
27
 
29
28
from gi.repository import GObject
30
29
 
55
54
        GObject.child_watch_add(pid, self._on_synaptic_exit, (tempf, deferred))
56
55
        return deferred
57
56
 
58
 
    def _on_synaptic_exit(self, pid, condition, (tempf, deferred)):
 
57
    def _on_synaptic_exit(self, pid, condition, userdata):
 
58
        (tempf, deferred) = userdata
59
59
        if tempf:
60
60
            tempf.close()
61
61
        if condition == 0: