From 47dfb3fac23721f76fc3084835f2c3c6382777ce Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Sun, 16 Mar 2014 20:42:27 +0100 Subject: python/progress.cc: Fix InstallProgress to set child_pid (LP: #1177720) We do not wait for a child at all otherwise. --- python/progress.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'python') diff --git a/python/progress.cc b/python/progress.cc index a7cf1afa..9b813d74 100644 --- a/python/progress.cc +++ b/python/progress.cc @@ -362,6 +362,9 @@ pkgPackageManager::OrderResult PyInstallProgress::Run(pkgPackageManager *pm) child_id = fork(); } + PyObject *child_o = PyLong_FromLong(child_id); + PyObject_SetAttrString(callbackInst, "child_pid", child_o); + Py_DECREF(child_o); #if 0 // FIXME: this needs to be merged into apt to support medium swaping if (child_id == 0) { -- cgit v1.2.3