1
0
Fork 0

empty is always constant, while size can be linear on older gcc versions. (wjp)

Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@4054
This commit is contained in:
Peter Veenstra 2017-09-26 07:50:31 +00:00
parent 32f0049408
commit c27b446d67

View file

@ -448,7 +448,7 @@ bool CBreakpoint::CheckBreakpoint(Bitu seg, Bitu off)
// Checks if breakpoint is valid and should stop execution
{
// Quick exit if there are no breakpoints
if (BPoints.size() == 0) return false;
if (BPoints.empty()) return false;
// Search matching breakpoint
std::list<CBreakpoint*>::iterator i;
@ -508,6 +508,8 @@ bool CBreakpoint::CheckBreakpoint(Bitu seg, Bitu off)
bool CBreakpoint::CheckIntBreakpoint(PhysPt adr, Bit8u intNr, Bit16u ahValue, Bit16u alValue)
// Checks if interrupt breakpoint is valid and should stop execution
{
if (BPoints.empty()) return false;
// Search matching breakpoint
std::list<CBreakpoint*>::iterator i;
CBreakpoint* bp;