Fix #50
Fix for #56 - Use java.net.URISyntaxException when parsing fails
Make parser stricter to avoid StackOverflowExceptions