[ros-dev] [ros-diffs] [janderwald] 44644: [SETUPAPI] - Implement SetupDiInstallDeviceInterfaces, SetupDiCreateDeviceInterfaceRegKeyW which are required to store device specific information

Gregor Schneider grschneider at gmail.com
Fri Dec 18 10:00:48 CET 2009


Most likely not, MSDN mentions "do not use" concerning this field.
Ref: http://msdn.microsoft.com/en-us/library/ms793004.aspx

2009/12/18 Hervé Poussineau <hpoussin at reactos.org>

> janderwald at svn.reactos.org a écrit :
> > Author: janderwald
> > Date: Fri Dec 18 05:37:15 2009
> > New Revision: 44644
> >
> > URL: http://svn.reactos.org/svn/reactos?rev=44644&view=rev
> > Log:
> > [SETUPAPI]
> > - Implement SetupDiInstallDeviceInterfaces,
> SetupDiCreateDeviceInterfaceRegKeyW which are required to store device
> specific information
> >
> > Modified:
> >     trunk/reactos/dll/win32/setupapi/devinst.c
> >     trunk/reactos/dll/win32/setupapi/interface.c
> >     trunk/reactos/dll/win32/setupapi/setupapi_private.h
> >
> >
> [...]
> > +
> > +    InsertTailList(&devInfo->InterfaceListHead, &DevItf->ListEntry);
> > +
> > +    memcpy(&DeviceInterfaceData.InterfaceClassGuid,
> &DevItf->InterfaceClassGuid, sizeof(GUID));
> > +    DeviceInterfaceData.cbSize = sizeof(SP_DEVICE_INTERFACE_DATA);
> > +    DeviceInterfaceData.Flags = DevItf->Flags;
> > +    DeviceInterfaceData.Reserved = (ULONG_PTR)DevItf;
> > +
> > +    hKey = SetupDiCreateDeviceInterfaceRegKeyW(DeviceInfoSet,
> &DeviceInterfaceData, 0, KEY_ALL_ACCESS, NULL, 0);
> > +    HeapFree(GetProcessHeap(), 0, DevItf);
> > +    if (hKey == INVALID_HANDLE_VALUE)
> > +    {
> > +        return FALSE;
> > +    }
> > +
> >
> Seems like you're keeping in DeviceInterfaceData.Reserved a pointer to a
> deleted structure... Is it intentional?
>
> _______________________________________________
> Ros-dev mailing list
> Ros-dev at reactos.org
> http://www.reactos.org/mailman/listinfo/ros-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-dev/attachments/20091218/c597553e/attachment.htm 


More information about the Ros-dev mailing list