![]() |
![]() |
| Paypal | FTP | CCD | Buscar | Trucos | Trabajo | Foros |
|
|||||||
| Registrarse | FAQ | Miembros | Calendario | Guía de estilo | Buscar | Temas de Hoy | Marcar Foros Como Leídos |
![]() |
|
|
Herramientas | Buscar en Tema | Desplegado |
|
|
|
#1
|
||||
|
||||
|
Pues acabo de probar lo siguiente.
En el constructor del hilo he puesto esto: Código:
__fastcall THiloDebugger(bool CreateSuspended, STARTUPINFO *startupInfo, TList *ListBPs, AnsiString Path, PROCESS_INFORMATION *processInfo, CONTEXT *context, DWORD *LastExcepAddress, TDebugger *Debugger); En el protected del THiloDebugger he añadido esto: Código:
TDebugger *Dbg; Código:
Dbg = Debugger; Código:
HiloDbg = new THiloDebugger(true, &si, ListaBPs, PathFile, &pi, &con, &LastExceptionAddress, this); Código:
void __fastcall THiloDebugger::OnCreateThreadDebugEventThread()
{
dwContinueStatus = Dbg->OnExitDebugEvent(&DebugEv);
}
Código:
[C++ Error] THiloDebugger.cpp(217): E2316 'OnExitDebugEvent' is not a member of 'TDebugger' |
|
#2
|
||||
|
||||
|
Vale, esto ya compila y corre y lanza el depurador y solo me falta un detalle. He creado esto:
En el protected del THiloDebugger: TEventDebugCallBack FuncEventos; En el Execute: Synchronize(GetFuncEvents); Este es el metodo: Código:
void __fastcall THiloDebugger::GetFuncEvents()
{
Dbg->GetCallBack(&FuncEventos);
}
Y aqui en el TDebugger:
// Obtener los CallBacks
void TDebugger::GetOnSystemBreakPoint(SYSTEMBREAKPOINT func){
func = FuncSystemBreakPoint;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnBPs(BREAKPOINT func){
func = FuncBPs;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnSingleStep(SINGLESTEP func){
func = FuncSingleStep;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnException(EXCEPTION func){
func = FuncException;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnCreateProcess(CREATEPROCESS func){
func = FuncCreateProcess;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnExitProcess(EXITPROCESS func){
func = FuncExitProcess;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnCreateThread(CREATETHREAD func){
func = FuncCreateThread;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnExitThread(EXITTHREAD func){
func = FuncExitThread;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnLoadDll(LOADDLL func){
func = FuncLoadDLL;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnUnLoadDll(UNLOADDLL func){
func = FuncUnLoadDLL;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnOutPutString(OUTPUTSTRING func){
func = FuncOutPutString;
}
//---------------------------------------------------------------------------
void TDebugger::GetOnRIP(RIP func){
func = FuncRIP;
}
//---------------------------------------------------------------------------
void TDebugger::GetCallBack(TEventDebugCallBack *tEstruc){
GetOnSystemBreakPoint(tEstruc->FuncSystemBreakPoint);
GetOnBPs(tEstruc->FuncBPs);
GetOnException(tEstruc->FuncException);
GetOnCreateProcess(tEstruc->FuncCreateProcess);
GetOnExitProcess(tEstruc->FuncExitProcess);
GetOnCreateThread(tEstruc->FuncCreateThread);
GetOnExitThread(tEstruc->FuncExitThread);
GetOnLoadDll(tEstruc->FuncLoadDLL);
GetOnUnLoadDll(tEstruc->FuncUnLoadDLL);
GetOnOutPutString(tEstruc->FuncOutPutString);
GetOnRIP(tEstruc->FuncRIP);
GetOnSingleStep(tEstruc->FuncSingleStep);
}
Última edición por ecfisa fecha: 29-03-2014 a las 01:26:54. Razón: Agregar etiquetas [code] |
|
#3
|
||||
|
||||
|
Hola aguml.
Por favor, no olvides usar las etiquetas [code] tu_codigo [/code] cuando pongas código C++ en el mensaje. Saludos ![]()
__________________
Daniel Didriksen Guía de estilo - Uso de las etiquetas - La otra guía de estilo .... |
|
#4
|
||||
|
||||
|
perdon, me di cuenta tarde de que se me olvidó y lo intente editar pero mo me aparecia la opcion de encapsular al editarlo y no cai en hacerlo manualmente poniendo las etiquetas a mano.
|
|
#5
|
||||
|
||||
|
Bueno al final lo he conseguido solucionar.
Gracias amigos. |
![]() |
| Herramientas | Buscar en Tema |
| Desplegado | |
|
|
Temas Similares
|
||||
| Tema | Autor | Foro | Respuestas | Último mensaje |
| Problemas con hilos y remobjects Pascal Script. | J.Slann | Varios | 4 | 19-11-2011 17:35:28 |
| Problemas con acceso telefonico a redes e hilos | ospaco69 | OOP | 0 | 08-08-2007 00:02:36 |
| problemas con hilos (Thead) | jmlifi | Varios | 2 | 20-03-2007 17:56:53 |
| problemas con Hilos (Thread) | jmlifi | Varios | 2 | 26-02-2007 15:29:21 |
| Builder c++ 6 y los hilos | javikanin | C++ Builder | 1 | 26-11-2004 14:49:10 |
|