mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] commands: of_dump: Fix return value
@ 2014-09-11 15:04 Teresa Gámez
  2014-09-12  5:42 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Teresa Gámez @ 2014-09-11 15:04 UTC (permalink / raw)
  To: barebox

In an error case the return value is set nicely
but 0 is always beeing returned.

Signed-off-by: Teresa Gámez <t.gamez@phytec.de>
---
 commands/of_dump.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/commands/of_dump.c b/commands/of_dump.c
index 1222ebf..513a4b8 100644
--- a/commands/of_dump.c
+++ b/commands/of_dump.c
@@ -34,7 +34,7 @@
 static int do_of_dump(int argc, char *argv[])
 {
 	int opt;
-	int ret;
+	int ret = 0;
 	int fix = 0;
 	struct device_node *root = NULL, *node, *of_free = NULL;
 	char *dtbfile = NULL;
@@ -117,7 +117,7 @@ out:
 	if (of_free)
 		of_delete_node(of_free);
 
-	return 0;
+	return ret;
 }
 
 BAREBOX_CMD_HELP_START(of_dump)
-- 
1.7.0.4


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-09-12  5:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-11 15:04 [PATCH] commands: of_dump: Fix return value Teresa Gámez
2014-09-12  5:42 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox