Bug 908821 - CLI client does not check passed options correctly
Summary: CLI client does not check passed options correctly
Keywords:
Status: NEW
Alias: None
Product: RHQ Project
Classification: Other
Component: CLI
Version: 4.5
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-07 15:33 UTC by Filip Brychta
Modified: 2022-03-31 04:28 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description Filip Brychta 2013-02-07 15:33:20 UTC
Description of problem:
I accidentally run 
./rhq-cli.sh -s 10.16.23.170 -r rhqadmin -p rhqadmin
instead of 
./rhq-cli.sh -s 10.16.23.170 -u rhqadmin -p rhqadmin 
and no error message was displayed.
When you run 
./rhq-cli.sh -s 10.16.23.170 -z rhqadmin -p rhqadmin
error message is displayed correclty.

Version-Release number of selected component (if applicable):
Version: 4.6.0-SNAPSHOT
Build Number: 73a33d5

How reproducible:
Always

Steps to Reproduce:
1. run ./rhq-cli.sh -s 10.16.23.170 -r rhqadmin -p rhqadmin

  
Actual results:
no error

Expected results:
Cli: invalid option -- r
rhq-cli.sh [-h] [-u user] [-p pass] [-P] [-s host] [-t port] [-v] [-f file]|[-c command]
Exception in thread "main" java.lang.IllegalArgumentException: Bad arguments specified on command line
	at org.rhq.enterprise.client.ClientMain$StartupConfiguration.process(ClientMain.java:124)
	at org.rhq.enterprise.client.ClientMain.main(ClientMain.java:177)


Note You need to log in before you can comment on or make changes to this bug.