Actions
Bug #5313
closedNullReferenceException from validate command line when invalid argument used
Start date:
2022-02-12
Due date:
% Done:
100%
Estimated time:
Legacy ID:
Applies to branch:
11, trunk
Fix Committed on Branch:
11, trunk
Fixed in Maintenance Release:
Platforms:
.NET, Java
Description
From Forum post https://saxonica.plan.io/boards/3/topics/8360
I have tried the validate option of SaxonCS from the command line, mistyping the -xsd option as -xs, that didn't give a clean error or warning (as the Java version of 10 EE does) but a NullReferenceException:
> SaxonCS.exe'validate -xs:assert-example1.xsd -s:sample1.xml
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Saxon.Eej.Validate.quit(String message, Int32 code) in C:\Users\ndw\saxondev\build\cs\Saxon\Eej\Validate.cs:line 301
at Saxon.Eej.Validate.doValidate(String[] args) in C:\Users\ndw\saxondev\build\cs\Saxon\Eej\Validate.cs:line 63
at Saxon.Eej.Validate.main(String[] args) in C:\Users\ndw\saxondev\build\cs\Saxon\Eej\Validate.cs:line 17
at Saxon.Cmd.Command.Main(String[] args) in C:\Users\ndw\saxondev\src\main\saxon-cs\engine\Saxon\Cmd\Command.cs:line 22
Problem reproduced.
Please register to edit this issue
Actions