diff options
author | Tom Tromey <tromey@redhat.com> | 2013-06-18 18:42:08 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2013-06-18 18:42:08 +0000 |
commit | 7eb5b6a468ab2e313dbfd2638228846f9cd43ca3 (patch) | |
tree | 9f08bf2c8b4c203be00c98b4aac1ea317f721035 /gdb/python | |
parent | 75f45fe57b0f1bb1de9485a9175e0bba723ccda2 (diff) | |
download | gdb-7eb5b6a468ab2e313dbfd2638228846f9cd43ca3.tar.gz |
* python/python.c (finish_python_initialization): Decref
'pythondir' on failure path as well.
Diffstat (limited to 'gdb/python')
-rw-r--r-- | gdb/python/python.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gdb/python/python.c b/gdb/python/python.c index c94198e2985..00092c739da 100644 --- a/gdb/python/python.c +++ b/gdb/python/python.c @@ -1771,10 +1771,9 @@ finish_python_initialization (void) goto fail; err = PyList_Insert (sys_path, 0, pythondir); + Py_DECREF (pythondir); if (err) goto fail; - - Py_DECREF (pythondir); } else goto fail; |