commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Keyes <j...@mac.com>
Subject Re: [CLI] [patch] Parser bug
Date Tue, 08 Oct 2002 22:30:08 GMT
Hi Pete,

Sorry about the delay in getting around to this.  I've it checked in
and the test is in BugsTest (13425).  Check it out when you get
a chance.  I modified the patch slightly so the no new variable is
required, it just checks to see if any arguments have been added
to the Option.

Thanks for your help and assistance.
-John K

On Monday, Sep 30, 2002, at 16:30 Etc/GMT, MADDOCKS,PETE 
(HP-Loveland,ex1) wrote:

> Hi John,
>
> We ran across a bug in the case where a missing required argument for 
> an
> option was only caught if the option was at the end of command line.
>
> So for the command:
> -----------------
> SYNOPSIS
> ndmp [ options ]
> -o, --old-password oldPassword
> Use this option to specify the old password.
>
> -n, --new-password newPassword
> Use this option to specify the new password
> -----------------
> 1. If the user types:
>    ndmp -o oldpassword -n
>    Then the Parser class correctly throws a MissingArgumentException.
>
> 2. However, if the user types:
>    ndmp -o -n newpassword
>    Then the Parser class does not throw the Missing ArgumentException.
>
> So I have fixed this bug in the processArgs() method in the Parser 
> class.
>
> Please let me know if you have questions about it.
>
> Thanks,
> Peter Maddocks
> HP NSS NAS Software Design Engineer
> peter_maddocks@hp.com
>
>
>
> <Parser.java.patch>--
> To unsubscribe, e-mail:   
> <mailto:commons-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: 
> <mailto:commons-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message