Fix return value of uo_redirect
authorSimon Marchi <simon.marchi@polymtl.ca>
Sun, 27 Nov 2016 03:05:25 +0000 (22:05 -0500)
committerSimon Marchi <simon.marchi@polymtl.ca>
Sun, 27 Nov 2016 03:05:25 +0000 (22:05 -0500)
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/ChangeLog
gdb/ui-out.c

index 21d10c4be3e67b319f8a0a4e742101a654c4ba2b..d6d5dc6554667952d18cbb980ed5dd6e9e3f6d59 100644 (file)
@@ -1,3 +1,8 @@
+2016-11-26  Simon Marchi  <simon.marchi@polymtl.ca>
+
+       * ui-out.c (uo_redirect): Return the return value from the
+       implementation function.
+
 2016-11-26  Simon Marchi  <simon.marchi@polymtl.ca>
 
        * ui-out.c (ui_out_destroy, uo_data_destroy): Remove.
index 407c349ebe59247f73de148b0a2d1d08a725cd7e..7f365457d25065a0b5f4fa49d0693a16e2b39fc1 100644 (file)
@@ -703,8 +703,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 */
This page took 0.03015 seconds and 4 git commands to generate.