This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 04/22] Fix return value of uo_redirect
- From: Simon Marchi <simon dot marchi at polymtl dot ca>
- To: gdb-patches at sourceware dot org
- Cc: Simon Marchi <simon dot marchi at polymtl dot ca>
- Date: Thu, 24 Nov 2016 10:24:10 -0500
- Subject: [PATCH 04/22] Fix return value of uo_redirect
- Authentication-results: sourceware.org; auth=none
- References: <20161124152428.24725-1-simon.marchi@polymtl.ca>
The wrapper uo_redirect seems like it should return the return value
from of implementation function, since callers rely on it, but it
doesn't.
gdb/ChangeLog:
* ui-out.c (uo_redirect): Return the return value from the
implementation function.
---
gdb/ui-out.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/gdb/ui-out.c b/gdb/ui-out.c
index 9ac22dd..a7fdcd0 100644
--- a/gdb/ui-out.c
+++ b/gdb/ui-out.c
@@ -705,8 +705,7 @@ uo_redirect (struct ui_out *uiout, struct ui_file *outstream)
{
if (!uiout->impl->redirect)
return -1;
- uiout->impl->redirect (uiout, outstream);
- return 0;
+ return uiout->impl->redirect (uiout, outstream);
}
/* local functions */
--
2.10.0