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.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/gdb/python/python.c b/gdb/python/python.c
index cd8ddfb..4a7cb28 100644
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@@ -720,11 +720,7 @@ gdbpy_parse_and_eval (PyObject *self, PyObject *args)
TRY_CATCH (except, RETURN_MASK_ALL)
{
- char *copy = xstrdup (expr_str);
- struct cleanup *cleanup = make_cleanup (xfree, copy);
-
- result = parse_and_eval (copy);
- do_cleanups (cleanup);
+ result = parse_and_eval (expr_str);
}
GDB_PY_HANDLE_EXCEPTION (except);