From 7f7a74948fc687403fdc73d1c2aa1a51ecc7518e Mon Sep 17 00:00:00 2001
From: Calen Pennington <cpennington@wgen.net>
Date: Thu, 29 Apr 2010 10:48:15 -0400
Subject: [PATCH] Exit with the return code from command.parse

Command.parse returns a non-zero return code in a variety of
circumstances. However, the func command line script (script/func) was
ignoring that return code, and thus was hiding a number of error
conditions.

This patch uses sys.exit to return the return codes from command.parse
to the command line user.
---
 scripts/func |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/scripts/func b/scripts/func
index da2f50e..7607ea8 100755
--- a/scripts/func
+++ b/scripts/func
@@ -25,7 +25,7 @@ import func.overlord.func_command as func_command
 myname, argv = sys.argv[0], sys.argv[1:]
 cli = func_command.FuncCommandLine()
 try:
-    cli.parse(argv)
+    sys.exit(cli.parse(argv))
 except Func_Client_Exception, e:
     print "ERROR:", e
     sys.exit(1)
-- 
1.6.6.1

