diff options
| author | Stephen D. Huston <shuston@apache.org> | 2009-09-16 17:01:09 +0000 |
|---|---|---|
| committer | Stephen D. Huston <shuston@apache.org> | 2009-09-16 17:01:09 +0000 |
| commit | 8443a9a3895491ca4cf4d406e6097374a5df51e6 (patch) | |
| tree | a7ffd78ff69a53ac3cb90a12b28e32a57d576420 /qpid/python | |
| parent | 9d1ab7d4f6a28fed66ecde80c7137df81abf6309 (diff) | |
| download | qpid-python-8443a9a3895491ca4cf4d406e6097374a5df51e6.tar.gz | |
Pass 0 ppid property if os.getppid() not supported; fixes QPID-1676
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@815884 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/python')
| -rw-r--r-- | qpid/python/qpid/delegates.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/qpid/python/qpid/delegates.py b/qpid/python/qpid/delegates.py index c74cc5a945..14111a88df 100644 --- a/qpid/python/qpid/delegates.py +++ b/qpid/python/qpid/delegates.py @@ -139,12 +139,18 @@ class Server(Delegate): class Client(Delegate): + ppid = 0 + try: + ppid = os.getppid() + except: + pass + PROPERTIES = {"product": "qpid python client", "version": "development", "platform": os.name, "qpid.client_process": os.path.basename(sys.argv[0]), "qpid.client_pid": os.getpid(), - "qpid.client_ppid": os.getppid()} + "qpid.client_ppid": ppid} def __init__(self, connection, username="guest", password="guest", mechanism="PLAIN", heartbeat=None): |
