KdpCopyCodeStream

INT64 __fastcall KdpCopyCodeStream(UINT64 Address, VOID *Buffer, UINT64 TotalSize, UINT64 Flags){
  int v4; 
  unsigned int v5; 
  INT64 result; 
  UINT64 Flagsa; 
  UINT64 Flagsb; 
  v4 = Flags;
  LODWORD(Flagsa) = Flags;
  v5 = TotalSize;
  LODWORD(result) = KdpCopyMemoryChunks(Address, Buffer, TotalSize, (unsigned int)TotalSize, Flagsa, 0i64);
  if( (int)result >= 0 )
    return 0i64;
  KdpOweBreakpoint = 1;
  if( (v4 & 5) == 5 )
  {
    LODWORD(Flagsb) = v4 | 0x40;
    LODWORD(result) = KdpCopyMemoryChunks(Address, Buffer, v5, v5, Flagsb, 0i64);
    if( (int)result >= 0 )
      return 259i64;
  }
  return result;
}

Referenced by:

KdpAddBreakpoint
KdpInsertBreakpoint
KdpRemoveBreakpoint
KdpSetOwedBreakpoints