VrpShouldOperateOnCall

INT64 __fastcall VrpShouldOperateOnCall(INT64 a1, _QWORD *a2, _QWORD *a3, UINT64 *a4){
  UINT64 *v4; 
  __int64 v7; 
  int v8; 
  __int64 v9; 
  INT64 result; 
  _QWORD *v11; 
  _QWORD *v12; 
  _QWORD *v13; 
  int v14; 
  int v15; 
  UINT64 v16; 
  __int64 v17; 
  __int64 v18; 
  __int64 v19; 
  __int64 v20[3]; 
  v4 = 0i64;
  v18 = 0i64;
  v19 = 0i64;
  v20[0] = 0i64;
  VrpGetContextsForNotifyInfo(a1, a2, &v18, &v19);
  v9 = v18;
  if( v18 )
  {
    *a3 = v18;
    *a4 = *(_QWORD *)(v9 + 40);
    return 1i64;
  }
  if( v19 )
  {
    v16 = *(_QWORD *)(v19 + 8);
    *a3 = 0i64;
    *a4 = v16;
    return 1i64;
  }
  if( v8 == 32 )
  {
    result = VRegEnabledInJob((UINT64 *)v20);
    if( (_DWORD)result )
    {
      *a4 = v20[0];
      goto LABEL_6;
    }
LABEL_5:
    *a4 = 0i64;
    result = 0i64;
LABEL_6:
    *a3 = 0i64;
    return result;
  }
  if( ((v8 - 27) & 0xFFFFFFFD) != 0 )
    goto LABEL_5;
  v11 = 0i64;
  v12 = *(_QWORD **)(*(_QWORD *)(v7 + 8) + 16i64);
  v13 = (_QWORD *)*v12;
  if( (_QWORD *)*v12 == v12 )
  {
LABEL_8:
    v14 = -1073741772;
  }
  else
  {
    while( 1 )
    {
      v17 = v13[2] - VRP_ORIGINAL_KEY_NAME_PARAMETER_GUID;
      if( !v17 )
        v17 = v13[3] - *(&VRP_ORIGINAL_KEY_NAME_PARAMETER_GUID + 1);
      if( !v17 )
        break;
      v13 = (_QWORD *)*v13;
      if( v13 == v12 )
        goto LABEL_8;
    }
    v11 = v13;
    v14 = 0;
  }
  v15 = v14;
  if( v14 >= 0 )
    v15 = 0;
  if( v15 < 0 )
    goto LABEL_5;
  *a3 = 0i64;
  result = 1i64;
  if( v14 >= 0 )
    v4 = v11 + 6;
  *a4 = *v4;
  return result;
}

Referenced by:

VrpRegistryCallback