1
0
Fork 0

DBG: Add "DbgGetBpList" prototype to bridgemain.h

DBG: Add a slot filed to BRIDGEBP for hardware breakpoints
This commit is contained in:
Sigmapic 2013-11-23 16:30:09 +01:00
parent 6b02f74e57
commit 3ea429ef5b
2 changed files with 19 additions and 0 deletions

View File

@ -100,6 +100,7 @@ struct BRIDGEBP
bool singleshoot;
char name[MAX_BREAKPOINT_SIZE];
char mod[MAX_MODULE_SIZE];
unsigned short slot;
};
struct BPMAP
@ -190,6 +191,7 @@ DLL_IMPEXP bool DbgGetRegDump(REGDUMP* regdump);
DLL_IMPEXP bool DbgValToString(const char* string, duint value);
DLL_IMPEXP bool DbgMemIsValidReadPtr(duint addr);
DLL_IMPEXP BPXTYPE DbgGetBpxTypeAt(duint addr);
DLL_IMPEXP int DbgGetBpList(BPXTYPE type, BPMAP* list);
//GUI functions
DLL_IMPEXP void GuiDisasmAt(duint addr, duint cip);

View File

@ -329,6 +329,7 @@ extern "C" DLL_EXPORT int _dbg_getbplist(BPXTYPE type, BPMAP* bplist)
int retcount=0;
std::vector<BRIDGEBP> bridgeList;
BRIDGEBP curBp;
unsigned short slot=0;
for(int i=0; i<bpcount; i++)
{
switch(type)
@ -363,11 +364,27 @@ extern "C" DLL_EXPORT int _dbg_getbplist(BPXTYPE type, BPMAP* bplist)
curBp.type=bp_memory;
break;
}
switch(((DWORD)list[i].titantype)>>8)
{
case UE_DR0:
slot=0;
break;
case UE_DR1:
slot=1;
break;
case UE_DR2:
slot=2;
break;
case UE_DR3:
slot=3;
break;
}
curBp.addr=list[i].addr;
curBp.enabled=list[i].enabled;
strcpy(curBp.mod, list[i].mod);
strcpy(curBp.name, list[i].name);
curBp.singleshoot=list[i].singleshoot;
curBp.slot=slot;
bridgeList.push_back(curBp);
retcount++;
}