mirror of
https://github.com/holub/mame
synced 2025-07-04 09:28:51 +03:00
Fixed verbose output of RAW device names for XP.
This commit is contained in:
parent
611358ad56
commit
2d85128b03
@ -1770,7 +1770,7 @@ static void rawinput_device_release(device_info *devinfo)
|
||||
|
||||
|
||||
//============================================================
|
||||
// rawinput_device_name
|
||||
// rawinput_device_improve_name
|
||||
//============================================================
|
||||
|
||||
static TCHAR *rawinput_device_improve_name(TCHAR *name)
|
||||
@ -1786,8 +1786,13 @@ static TCHAR *rawinput_device_improve_name(TCHAR *name)
|
||||
TCHAR *chdst;
|
||||
LONG result;
|
||||
|
||||
// The RAW name received is formatted as:
|
||||
// \??\type-id#hardware-id#instance-id#{DeviceClasses-id}
|
||||
// XP starts with \??\
|
||||
// Vista64 starts with \\?\
|
||||
|
||||
// ensure the name is something we can handle
|
||||
if (_tcsncmp(name, TEXT("\\\\?\\"), 4) != 0)
|
||||
if (_tcsncmp(name, TEXT("\\\\?\\"), 4) != 0 && _tcsncmp(name, TEXT("\\??\\"), 4) != 0)
|
||||
return name;
|
||||
|
||||
// allocate a temporary string and concatenate the base path plus the name
|
||||
|
Loading…
Reference in New Issue
Block a user