forked from Imagelibrary/binutils-gdb
* python/py-prettyprint.c (gdbpy_get_display_hint): Don't use
'hint' if it is NULL.
This commit is contained in:
@@ -229,10 +229,12 @@ gdbpy_get_display_hint (PyObject *printer)
|
||||
return NULL;
|
||||
|
||||
hint = PyObject_CallMethodObjArgs (printer, gdbpy_display_hint_cst, NULL);
|
||||
if (gdbpy_is_string (hint))
|
||||
result = python_string_to_host_string (hint);
|
||||
if (hint)
|
||||
Py_DECREF (hint);
|
||||
{
|
||||
if (gdbpy_is_string (hint))
|
||||
result = python_string_to_host_string (hint);
|
||||
Py_DECREF (hint);
|
||||
}
|
||||
else
|
||||
gdbpy_print_stack ();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user