Given a filename such as "AKKDATA_1_AKKDATA_1 MENGDE_DÅ PG2_ExpressionVariable.cpp" src2srcml.exe version "Trunk 19109c Thu May 22 09:18:31 2014 -0400" writes the output file in encoding ISO-8859-1 but with an xml declaration that indicates UTF-8. The result is that XElement.Load, when passed a FileStream, throws an encoding-related exception. Passing the '-x "ISO-8859-1"' option to src2srcml.exe results in an empty output file.
Best solution: Fix src2srcml.exe.
Workaround for SrcML.NET: Wrap the FileStream in a StreamReader and pass that StreamReader to XElement.Load.
Given a filename such as "AKKDATA_1_AKKDATA_1 MENGDE_DÅ PG2_ExpressionVariable.cpp" src2srcml.exe version "Trunk 19109c Thu May 22 09:18:31 2014 -0400" writes the output file in encoding ISO-8859-1 but with an xml declaration that indicates UTF-8. The result is that XElement.Load, when passed a FileStream, throws an encoding-related exception. Passing the '-x "ISO-8859-1"' option to src2srcml.exe results in an empty output file.
Best solution: Fix src2srcml.exe.
Workaround for SrcML.NET: Wrap the FileStream in a StreamReader and pass that StreamReader to XElement.Load.