Commit 404cee2a authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

setupapi: Set the DeviceDesc value in SetupDiInstallDevice().

At least one PnP enumeration utility expects this. Signed-off-by: 's avatarZebediah Figura <z.figura12@gmail.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent 7d152715
......@@ -4720,7 +4720,7 @@ BOOL WINAPI SetupDiInstallDevice(HDEVINFO devinfo, SP_DEVINFO_DATA *device_data)
static const WCHAR addserviceW[] = {'A','d','d','S','e','r','v','i','c','e',0};
static const WCHAR rootW[] = {'r','o','o','t','\\',0};
WCHAR section[LINE_LEN], section_ext[LINE_LEN], subsection[LINE_LEN], inf_path[MAX_PATH], *extptr, *filepart;
WCHAR svc_name[LINE_LEN];
WCHAR svc_name[LINE_LEN], field[LINE_LEN];
UINT install_flags = SPINST_ALL;
HKEY driver_key, device_key;
SC_HANDLE manager, service;
......@@ -4747,6 +4747,10 @@ BOOL WINAPI SetupDiInstallDevice(HDEVINFO devinfo, SP_DEVINFO_DATA *device_data)
return FALSE;
SetupFindFirstLineW(hinf, driver->mfg_key, driver->description, &ctx);
SetupGetStringFieldW(&ctx, 0, field, ARRAY_SIZE(field), NULL);
RegSetValueExW(device->key, L"DeviceDesc", 0, REG_SZ, (BYTE *)field, wcslen(field) * sizeof(WCHAR));
SetupGetStringFieldW(&ctx, 1, section, ARRAY_SIZE(section), NULL);
SetupDiGetActualSectionToInstallW(hinf, section, section_ext, ARRAY_SIZE(section_ext), NULL, &extptr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment