Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.5.3
-
None
Description
Adding an empty parameter to the query string will make wicket crash.
http://www.example.com/?oneParam&
How to reproduce in test:
PageParameters params = new PageParameters();
params.set("","");
params.getAllNamed();
Cause:
Wicket accepts empty parameters, but when encoding the url for a rendered page it will call params.getAllNamed().
params.getAllNamed() instantiates new NamedPairs, which calls Args.notEmpty() on the key during instantiation, causing the application to crash.
The NamedPair constructor should probably allow empty string as a key, and call Args.notNull() on the key in stead.