From 269f82e5eb0aa5d5b4c1accc858f95b62bc16df4 Mon Sep 17 00:00:00 2001 From: Paul Pluzhnikov Date: Fri, 13 Nov 2009 17:17:57 +0000 Subject: [PATCH] gdb/ChangeLog: 2009-11-13 Paul Pluzhnikov * python/py-prettyprint.c (print_string_repr): Suppress address printing testsuite/ChangeLog: 2009-11-13 Paul Pluzhnikov * gdb.python/py-prettyprint.exp: Adjust. --- gdb/ChangeLog | 5 +++++ gdb/python/py-prettyprint.c | 7 ++++++- gdb/testsuite/ChangeLog | 4 ++++ gdb/testsuite/gdb.python/py-prettyprint.exp | 6 +++--- 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5111dbc28f6..7bfd1a88a42 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2009-11-13 Paul Pluzhnikov + + * python/py-prettyprint.c (print_string_repr): Suppress + address printing + 2009-11-13 Tristan Gingold * avr-tdep.c (avr_push_dummy_call): Fix endianness issue and avoid diff --git a/gdb/python/py-prettyprint.c b/gdb/python/py-prettyprint.c index 5d696c86d3d..19818e63f03 100644 --- a/gdb/python/py-prettyprint.c +++ b/gdb/python/py-prettyprint.c @@ -209,7 +209,12 @@ print_string_repr (PyObject *printer, const char *hint, Py_DECREF (py_str); } else if (replacement) - common_val_print (replacement, stream, recurse, options, language); + { + struct value_print_options opts = *options; + + opts.addressprint = 0; + common_val_print (replacement, stream, recurse, &opts, language); + } else gdbpy_print_stack (); } diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 42960998dee..b6d9c791466 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2009-11-13 Paul Pluzhnikov + + * gdb.python/py-prettyprint.exp: Adjust. + 2009-11-12 Daniel Jacobowitz * lib/cell.exp (skip_cell_tests): Clean up test files before diff --git a/gdb/testsuite/gdb.python/py-prettyprint.exp b/gdb/testsuite/gdb.python/py-prettyprint.exp index 14119f075be..f8cf36d4964 100644 --- a/gdb/testsuite/gdb.python/py-prettyprint.exp +++ b/gdb/testsuite/gdb.python/py-prettyprint.exp @@ -99,10 +99,10 @@ proc run_lang_tests {lang} { gdb_py_test_silent_cmd "set print elements 200" "" 1 } - gdb_test "print x" " = $hex \"this is x\"" - gdb_test "print cstring" " = $hex \"const string\"" + gdb_test "print x" " = \"this is x\"" + gdb_test "print cstring" " = \"const string\"" - gdb_test "print c" " = container $hex \"container\" with 2 elements = {$nl *.0. = 23,$nl *.1. = 72$nl}" + gdb_test "print c" " = container \"container\" with 2 elements = {$nl *.0. = 23,$nl *.1. = 72$nl}" gdb_test "continue" "Program exited normally\." -- 2.30.2