Geoff Chappell - Software Analyst
Reads an Internet Explorer registry setting that’s defined to have a type suitable for interpretation as a boolean.
HRESULT IERegGetDw ( UINT uSetting, BOOL *pbData);
The uSetting argument is an index that identifies the setting. For a list of supported settings, see the general notes on the Internet Explorer Registry API.
The pbData argument provides the address of a variable that is to receive a boolean interpretation of the setting’s data.
The function returns zero for success, else an error code.
If pbData is NULL, the function cannot do anything useful, and fails (returning E_POINTER).
Interpretation of the data depends on the type that is defined for the setting. Presumably by oversight, the function does not first check that the given index is supported: a value sufficiently far out of range will crash the process by inducing the function to read from an invalid address.
If the setting is defined as having REG_DWORD data, the function reads the setting as if for the IERegGetDw function, but returns TRUE or FALSE via pbData according to whether data for the setting is non-zero or zero.
If the setting is defined as having REG_SZ data, the function reads the setting as if for the IERegGetWz function, into a buffer sufficient for 8 characters. It returns TRUE via pbData if the case-insensitive string data is YES, TRUE or 1, or FALSE for NO, FALSE or 0.
Possible error codes from either registry search are:
The IERegGetBool function is exported from IERTUTIL as ordinal 166 in version 8.0 and higher.