Auto-detect UTF8 instead of assuming ANSI for device names.

This commit is contained in:
Matthias Mailänder
2016-05-20 21:22:10 +02:00
parent e47383a4fa
commit 1df5e556c6

View File

@@ -64,7 +64,7 @@ namespace OpenRA.Platforms.Default
do
{
var str = Marshal.PtrToStringAnsi(next);
var str = Marshal.PtrToStringAuto(next);
next += str.Length + 1;
devices.Add(str);
} while (Marshal.ReadByte(next) != 0);