Exemple #1
0
void
ExtExec(PCSTR Command)
{
	ExtOut("Exec: %s\n", Command);
    g_ExtControl->Execute(DEBUG_OUTCTL_ALL_CLIENTS, Command,DEBUG_EXECUTE_DEFAULT);
	//g_ExtControl->Execute(DEBUG_OUTCTL_LOG_ONLY, Command,DEBUG_EXECUTE_DEFAULT);
}
Exemple #2
0
void __cdecl
ExtErr(PCSTR Format, ...)
{
    va_list Args;
    
    va_start(Args, Format);
    g_ExtControl->OutputVaList(DEBUG_OUTPUT_ERROR, Format, Args);
    va_end(Args);
}
Exemple #3
0
void __cdecl
ExtOut(PCSTR Format, ...)
{
    va_list Args;
    
    va_start(Args, Format);
    //g_ExtControl->OutputVaList(DEBUG_OUTPUT_NORMAL, Format, Args);
	g_ExtControl->ControlledOutputVaList(DEBUG_OUTCTL_ALL_CLIENTS, DEBUG_OUTPUT_NORMAL, Format, Args);
	
    va_end(Args);
}
Exemple #4
0
extern "C" HRESULT
ArchQuery(void)
{
    ULONG targetArchitecture;
    IMachine* targetMachine = NULL;

    g_ExtControl->GetExecutingProcessorType(&targetArchitecture);

#ifdef SOS_TARGET_AMD64
    if(targetArchitecture == IMAGE_FILE_MACHINE_AMD64)
    {
        targetMachine = AMD64Machine::GetInstance();
    }
#endif // SOS_TARGET_AMD64
#ifdef SOS_TARGET_X86
    if (targetArchitecture == IMAGE_FILE_MACHINE_I386)
    {
        targetMachine = X86Machine::GetInstance();
    }
#endif // SOS_TARGET_X86
#ifdef SOS_TARGET_ARM
    if (targetArchitecture == IMAGE_FILE_MACHINE_ARMNT)
    {
        targetMachine = ARMMachine::GetInstance();
    }
#endif // SOS_TARGET_ARM
#ifdef SOS_TARGET_ARM64
    if (targetArchitecture == IMAGE_FILE_MACHINE_ARM64)
    {
        targetMachine = ARM64Machine::GetInstance();
    }
#endif // SOS_TARGET_ARM64

    if (targetMachine == NULL)
    {
        g_targetMachine = NULL;
        ExtErr("SOS does not support the current target architecture.\n");
        return E_FAIL;
    }

    g_targetMachine = targetMachine;
    return S_OK;
}
Exemple #5
0
void
ExtExec(PCSTR Command)
{
    g_ExtControl->Execute(DEBUG_OUTCTL_ALL_CLIENTS, Command,
                          DEBUG_EXECUTE_DEFAULT);
}