mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 10:19:23 +02:00
decompiler-cpp: Add missing for-loop index variable check
Prevent indexing out of bounds
This commit is contained in:
parent
2a7897c366
commit
fdde0743e0
1 changed files with 3 additions and 3 deletions
|
@ -1844,7 +1844,7 @@ void IfcProtooverride::execute(istream &s)
|
|||
s >> ws;
|
||||
Address callpoint(parse_machaddr(s,discard,*dcp->conf->types));
|
||||
int4 i;
|
||||
for(i=0;dcp->fd->numCalls();++i)
|
||||
for(i=0;i<dcp->fd->numCalls();++i)
|
||||
if (dcp->fd->getCallSpecs(i)->getOp()->getAddr() == callpoint) break;
|
||||
if (i == dcp->fd->numCalls())
|
||||
throw IfaceExecutionError("No call is made at this address");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue