[PATCH] SCRATCH - Fix unspecified action bug
Jan Tluka
jtluka at redhat.com
Fri May 24 08:53:20 UTC 2013
Forgot to include 'dump' target. I've resent another patch.
Fri, May 24, 2013 at 10:38:30AM CEST, jtluka at redhat.com wrote:
>If a user omitted action in the lnst-ctl arguments the script would continue
>in its execution with no obvious error. I fixed the code so the user gets
>information about incorrect arguments and script stops if no action is
>specified.
>
>Signed-off-by: Jan Tluka <jtluka at redhat.com>
>---
> lnst-ctl | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
>diff --git a/lnst-ctl b/lnst-ctl
>index dcb4cd2..364e73c 100755
>--- a/lnst-ctl
>+++ b/lnst-ctl
>@@ -143,12 +143,12 @@ def main():
> log_dir=config.get_option('environment', 'log_dir'),
> log_subdir=date)
>
>- if not args:
>+ action = args.pop()
>+
>+ if not action in {'run', 'config_only', 'match_setup'}:
> logging.error("No action command passed")
> usage();
>
>- action = args.pop()
>-
> summary = []
>
> res_serializer = NetTestResultSerializer()
>--
>1.7.11.7
>
>_______________________________________________
>LNST-developers mailing list
>LNST-developers at lists.fedorahosted.org
>https://lists.fedorahosted.org/mailman/listinfo/lnst-developers
More information about the LNST-developers
mailing list