From cda45b5131c3546b870d8cea3191fb29df182b27 Mon Sep 17 00:00:00 2001 From: ENikS Date: Tue, 23 Sep 2014 18:33:16 -0400 Subject: Reinitializing list's begin iterator after few elements were erased from the head --- src/script/script.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/script') diff --git a/src/script/script.h b/src/script/script.h index 4c9ac74b78..b5336eb997 100644 --- a/src/script/script.h +++ b/src/script/script.h @@ -544,7 +544,7 @@ public: { while (end() - pc >= (long)b.size() && memcmp(&pc[0], &b[0], b.size()) == 0) { - erase(pc, pc + b.size()); + pc = erase(pc, pc + b.size()); ++nFound; } } -- cgit v1.2.3