CmGetDeviceInterfaceMappedPropertyLocales

NTSTATUS __stdcall CmGetDeviceInterfaceMappedPropertyLocales(
        _DEVPROPKEY *PropertyKey,
        WCHAR *Buffer,
        UINT64 BufferLength,
        UINT64 *RequiredLength){
  DEVPROPKEY **v4; 
  NTSTATUS v5; 
  unsigned int v6; 
  DEVPROPKEY *v7; 
  UINT64 v8; 
  DEVPROPKEY **v9; 
  unsigned int v10; 
  DEVPROPKEY *v11; 
  UINT64 v12; 
  _WORD *v14; 
  int v15; 
  _DWORD *v16; 

  v4 = &off_140983A68;
  v5 = -1073741802;
  v6 = 0;
  *v16 = 0;
  while( 1 )
  {
    v7 = *v4;
    if( *v4 && *((_DWORD *)RequiredLength + 4) == v7->pid )
    {
      v8 = *RequiredLength - *(_QWORD *)&v7->fmtid.Data1;
      if( *RequiredLength == *(_QWORD *)&v7->fmtid.Data1 )
        v8 = RequiredLength[1] - *(_QWORD *)v7->fmtid.Data4;
      if( !v8 )
        break;
    }
    ++v6;
    v4 += 2;
    if( v6 >= 3 )
    {
      v9 = &off_140983FA0;
      v10 = 0;
      while( 1 )
      {
        v11 = *v9;
        if( *((_DWORD *)RequiredLength + 4) == (*v9)->pid )
        {
          v12 = *RequiredLength - *(_QWORD *)&v11->fmtid.Data1;
          if( *RequiredLength == *(_QWORD *)&v11->fmtid.Data1 )
            v12 = RequiredLength[1] - *(_QWORD *)v11->fmtid.Data4;
          if( !v12 )
            break;
        }
        ++v10;
        v9 += 2;
        if( v10 >= 4 )
          return v5;
      }
      break;
    }
  }
  *v16 = 1;
  if( !v15 )
    return -1073741789;
  v5 = 0;
  *v14 = 0;
  return v5;
}

Referenced by:

PnpDispatchDeviceInterface