RegUnLoadKey function Null safety advapi32

int RegUnLoadKey(
  1. int hKey,
  2. Pointer<Utf16> lpSubKey
)

Unloads the specified registry key and its subkeys from the registry.

LSTATUS RegUnLoadKeyW(
  HKEY    hKey,
  LPCWSTR lpSubKey);

Implementation

int RegUnLoadKey(int hKey, Pointer<Utf16> lpSubKey) {
  final _RegUnLoadKey = _advapi32.lookupFunction<
      Int32 Function(IntPtr hKey, Pointer<Utf16> lpSubKey),
      int Function(int hKey, Pointer<Utf16> lpSubKey)>('RegUnLoadKeyW');
  return _RegUnLoadKey(hKey, lpSubKey);
}