chiark / gitweb /
fishdescriptor: Make Donor.pid a public member
authorIan Jackson <ian.jackson@eu.citrix.com>
Mon, 23 Oct 2017 16:38:42 +0000 (17:38 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Mon, 23 Oct 2017 16:38:42 +0000 (17:38 +0100)
Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
fishdescriptor/py/fishdescriptor/fish.py

index ff77fa9..15ad766 100644 (file)
@@ -12,7 +12,7 @@ def _shuffle_fd3():
 
 class Donor():
     def __init__(d, pid):
-        d._pid = pid
+        d.pid = pid
         d._sp = subprocess.Popen(
             preexec_fn = _shuffle_fd3,
             stdin = subprocess.PIPE,
@@ -97,9 +97,9 @@ class Donor():
         sockdir = d._sock_dir(euid)
         d.mkdir(sockdir)
 
-        sockname = '%s/%s,%d' % (sockdir, os.uname().nodename, d._pid)
+        sockname = '%s/%s,%d' % (sockdir, os.uname().nodename, d.pid)
 
-        target_root = '/proc/%d/root' % d._pid
+        target_root = '/proc/%d/root' % d.pid
         if not d._exists(target_root):
             target_root = ''