浏览代码

Merge pull request #14513 from obscuren/allocate-stack

core/vm: allocate stack to 1024
Péter Szilágyi 8 年之前
父节点
当前提交
b596b4ba5b
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      core/vm/stack.go

+ 1 - 1
core/vm/stack.go

@@ -29,7 +29,7 @@ type Stack struct {
 }
 }
 
 
 func newstack() *Stack {
 func newstack() *Stack {
-	return &Stack{}
+	return &Stack{data: make([]*big.Int, 0, 1024)}
 }
 }
 
 
 func (st *Stack) Data() []*big.Int {
 func (st *Stack) Data() []*big.Int {