Index: src/regexp-stack.cc |
diff --git a/src/regexp-stack.cc b/src/regexp-stack.cc |
index fda7253edcee150a6cac9668e0f9db726bd135ce..325a1496c98c9a26d05c9fffc1c97be132e401f0 100644 |
--- a/src/regexp-stack.cc |
+++ b/src/regexp-stack.cc |
@@ -51,6 +51,7 @@ RegExpStack::RegExpStack() |
RegExpStack::~RegExpStack() { |
+ thread_local_.Free(); |
} |
@@ -72,7 +73,7 @@ char* RegExpStack::RestoreStack(char* from) { |
void RegExpStack::Reset() { |
- if (thread_local_.memory_size_ >= kMinimumStackSize) { |
+ if (thread_local_.memory_size_ > kMinimumStackSize) { |
DeleteArray(thread_local_.memory_); |
thread_local_ = ThreadLocal(); |
} |