File tree 1 file changed +4
-7
lines changed
1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -262,18 +262,15 @@ void CBudgetManager::AddProposal(CBudgetProposal& prop)
262
262
263
263
void CBudgetManager::CheckAndRemove ()
264
264
{
265
- return ;
266
-
267
- // segfault happening in the following code sometimes
268
265
std::map<uint256, CFinalizedBudget>::iterator it = mapFinalizedBudgets.begin ();
269
266
while (it != mapFinalizedBudgets.end ())
270
267
{
271
268
CFinalizedBudget* prop = &((*it).second );
272
269
if (!prop->IsValid ()){
273
- mapFinalizedBudgets.erase (it);
270
+ mapFinalizedBudgets.erase (it++ );
274
271
} else {
275
272
prop->AutoCheck ();
276
- it++ ;
273
+ ++it ;
277
274
}
278
275
}
279
276
@@ -282,9 +279,9 @@ void CBudgetManager::CheckAndRemove()
282
279
{
283
280
CBudgetProposal* prop = &((*it2).second );
284
281
if (!prop->IsValid ()){
285
- mapProposals.erase (it2);
282
+ mapProposals.erase (it2++ );
286
283
} else {
287
- it2++ ;
284
+ ++it2 ;
288
285
}
289
286
}
290
287
}
You can’t perform that action at this time.
0 commit comments