Issue Details (XML | Word | Printable)

Key: VALIDATOR-226
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Niall Pemberton
Reporter: Lian Ort
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Commons Validator

Null-Stream input to ValidatorResources leads to MalformedURLExceptions

Created: 26/Feb/07 04:33 PM   Updated: 12/Nov/07 07:25 PM
Return to search
Component/s: Framework
Affects Version/s: 1.3.1 Release
Fix Version/s: 1.4

Time Tracking:
Not Specified

Environment: Should be regardless to OS or Java version

Resolution Date: 26/Feb/07 05:19 PM


 Description  « Hide
Providing the constructor of ValidatorResources with a null InputStream leads to a MalformedURLException,
which leads the user (trying to find his error) in a complete wrong direction. Perhaps returning a NullPointerException or
an IllegalArgumentException seems to be a better understandable reaction.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Niall Pemberton added a comment - 26/Feb/07 05:19 PM
Thanks for reporting this - I've fixed this in validator (now throws an IllegalArgumentException indicating that the InputStream is null).

I also created an issue for this against Commons Digester (DIGESTER-111) - which also failed to check that the InputStream isn't null.

Niall