From 68dadef54c216f7ec75c27d74193897b18c5f9ab Mon Sep 17 00:00:00 2001 From: Markus Metzger Date: Mon, 20 Jun 2016 11:12:14 +0200 Subject: python: accept address and explicit locations in gdb.decode_line The gdb.decode_line python function is documented to support the same location expressions as the "break" command. It currently expects a linespec location. Instead of creating a linespec location directly, create the location via string_to_event_location_basic. --- gdb/python/python.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/python/python.c') diff --git a/gdb/python/python.c b/gdb/python/python.c index b00b70b..7e34d26 100644 --- a/gdb/python/python.c +++ b/gdb/python/python.c @@ -740,7 +740,7 @@ gdbpy_decode_line (PyObject *self, PyObject *args) if (arg != NULL) { - location = new_linespec_location (&arg); + location = string_to_event_location_basic (&arg, python_language); make_cleanup_delete_event_location (location); } -- cgit v1.1