Fixed wrong encodings for SDK-strings.

This should resolve #24
This commit is contained in:
DarthAffe committed 2015-10-16 17:42:33 +02:00
1 parent 21aca569ed
commit a2a0300882
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -54,8 +54,8 @@ namespace CUE.NET.Devices.Generic
/// <param name="nativeDetails">The native CorsairProtocolDetails-struct</param>
internal CorsairProtocolDetails(_CorsairProtocolDetails nativeDetails)
{
this.SdkVersion = nativeDetails.sdkVersion == IntPtr.Zero ? null : Marshal.PtrToStringAuto(nativeDetails.sdkVersion);
this.ServerVersion = nativeDetails.serverVersion == IntPtr.Zero ? null : Marshal.PtrToStringAuto(nativeDetails.serverVersion);
this.SdkVersion = nativeDetails.sdkVersion == IntPtr.Zero ? null : Marshal.PtrToStringAnsi(nativeDetails.sdkVersion);
this.ServerVersion = nativeDetails.serverVersion == IntPtr.Zero ? null : Marshal.PtrToStringAnsi(nativeDetails.serverVersion);
this.SdkProtocolVersion = nativeDetails.sdkProtocolVersion;
this.ServerProtocolVersion = nativeDetails.serverProtocolVersion;
this.BreakingChanges = nativeDetails.breakingChanges != 0;
+1 -1
View File
@@ -35,7 +35,7 @@ namespace CUE.NET.Devices.Generic
internal GenericDeviceInfo(_CorsairDeviceInfo nativeInfo)
{
this.Type = nativeInfo.type;
this.Model = nativeInfo.model == IntPtr.Zero ? null : Marshal.PtrToStringAuto(nativeInfo.model);
this.Model = nativeInfo.model == IntPtr.Zero ? null : Marshal.PtrToStringAnsi(nativeInfo.model);
this.CapsMask = (CorsairDeviceCaps)nativeInfo.capsMask;
}