fix for bugzilla 7693

another test

better to throw on invalid input

whitespace

merged comments