diff mbox

(obvious): Fix a comment, and pass stream to cb_data.

Message ID 20180524212755.7995-1-philippe.waroquiers@skynet.be
State New
Headers show

Commit Message

Philippe Waroquiers May 24, 2018, 9:27 p.m. UTC
iterate_over_block_arg_vars is a void function, so does
not return 1 or 0.
print_frame_arg_vars tells it prints on STREAM,
so pass STREAM in the cb_data, not gdb_stdout.

gdb/ChangeLog

2018-05-24  Philippe Waroquiers  <philippe.waroquiers@skynet.be>

	* stack.c (iterate_over_block_arg_vars): Fix comment.
	(print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
---
 gdb/ChangeLog | 5 +++++
 gdb/stack.c   | 6 ++----
 2 files changed, 7 insertions(+), 4 deletions(-)
diff mbox

Patch

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 503b34f26a..6a1aae8523 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@ 
+2018-05-24  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
+
+	* stack.c (iterate_over_block_arg_vars): Fix comment.
+	(print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
+
 2018-05-24  Andrew Burgess  <andrew.burgess@embecosm.com>
 
 	PR gdb/23203
diff --git a/gdb/stack.c b/gdb/stack.c
index 98a21842e7..016ee1d58b 100644
--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -2059,9 +2059,7 @@  info_locals_command (const char *args, int from_tty)
 			  0, gdb_stdout);
 }
 
-/* Iterate over all the argument variables in block B.
-
-   Returns 1 if any argument was walked; 0 otherwise.  */
+/* Iterate over all the argument variables in block B.  */
 
 void
 iterate_over_block_arg_vars (const struct block *b,
@@ -2121,7 +2119,7 @@  print_frame_arg_vars (struct frame_info *frame, struct ui_file *stream)
 
   cb_data.frame_id = get_frame_id (frame);
   cb_data.num_tabs = 0;
-  cb_data.stream = gdb_stdout;
+  cb_data.stream = stream;
   cb_data.values_printed = 0;
 
   iterate_over_block_arg_vars (SYMBOL_BLOCK_VALUE (func),