You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Haixing Hu (JIRA)" <ji...@apache.org> on 2010/02/09 16:51:27 UTC

[jira] Commented: (CLI-195) Fix some iterator boundary check bugs.

    [ https://issues.apache.org/jira/browse/CLI-195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12831502#action_12831502 ] 

Haixing Hu commented on CLI-195:
--------------------------------

by the way, the patch is applied to the svn revision: 908084

> Fix some iterator boundary check bugs.
> --------------------------------------
>
>                 Key: CLI-195
>                 URL: https://issues.apache.org/jira/browse/CLI-195
>             Project: Commons CLI
>          Issue Type: Bug
>          Components: CLI-2.x
>    Affects Versions: Nightly Builds
>         Environment: JDK 5
>            Reporter: Haixing Hu
>            Priority: Critical
>             Fix For: Nightly Builds
>
>         Attachments: cli2-jdk1.5-patch-with-boundary-fix.patch
>
>   Original Estimate: 0.17h
>  Remaining Estimate: 0.17h
>
> This patch can be applied to the current svn checked out version of cli2 (2010-Feb-9th).
> It will make the cli2 compatible to JDK 5 generic type, eliminating all compiling warnings,
> and fix some minor but critical iterator boundary check bugs.
> The bug could be found in the following way: creating some Option object WITHOUT description,
> and use a HelpFormatter to print the helping message, then a NoSuchElementException will be thrown.
> This is because the HelpFormatter.printHelp() did not correctly check the empty status of descriptionIterator.
> And moreover, some implementation of Option.processParent() method did not check the empty status
> of the argument "ListIterator<String> arguments".

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.