CmCloseRmHandle

__int64 __fastcall CmCloseRmHandle(__int64 a1, char a2){
  __int64 result; 
  result = 0i64;
  if( a1 && (*(_DWORD *)(a1 + 64) == 1 || a2 == 1) )
  {
    result = *(_QWORD *)(a1 + 48);
    *(_QWORD *)(a1 + 48) = 0i64;
  }
  return result;
}

Referenced by:

CmShutdownSystem
CmpPerformUnloadKey
CmpTryToRundownHive