aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/python.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python/python.c')
-rw-r--r--gdb/python/python.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/python/python.c b/gdb/python/python.c
index c28f98b..14da62c 100644
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@@ -730,7 +730,7 @@ gdbpy_decode_line (PyObject *self, PyObject *args)
PyObject *result = NULL;
PyObject *return_result = NULL;
PyObject *unparsed = NULL;
- struct event_location *location;
+ struct event_location *location = NULL;
if (! PyArg_ParseTuple (args, "|s", &arg))
return NULL;
@@ -747,7 +747,7 @@ gdbpy_decode_line (PyObject *self, PyObject *args)
TRY
{
- if (arg)
+ if (location != NULL)
sals = decode_line_1 (location, 0, 0, 0);
else
{