diff --git a/pkg/core/interop_system.go b/pkg/core/interop_system.go index b20e8a7da..6cbb2109e 100644 --- a/pkg/core/interop_system.go +++ b/pkg/core/interop_system.go @@ -69,7 +69,6 @@ func storageDelete(ic *interop.Context) error { if stc.ReadOnly { return errors.New("StorageContext is read only") } - ic.VM.AddGas(ic.Chain.GetPolicer().GetStoragePrice()) key := ic.VM.Estack().Pop().Bytes() return ic.DAO.DeleteStorageItem(stc.ID, key) } diff --git a/pkg/core/interops.go b/pkg/core/interops.go index ee99b9eed..6b4e88ac9 100644 --- a/pkg/core/interops.go +++ b/pkg/core/interops.go @@ -57,7 +57,7 @@ var systemInterops = []interop.Function{ {Name: interopnames.SystemRuntimeNotify, Func: runtime.Notify, Price: 1 << 15, RequiredFlags: callflag.AllowNotify, ParamCount: 2}, {Name: interopnames.SystemRuntimePlatform, Func: runtime.Platform, Price: 1 << 3}, - {Name: interopnames.SystemStorageDelete, Func: storageDelete, Price: 0, + {Name: interopnames.SystemStorageDelete, Func: storageDelete, Price: 1 << 15, RequiredFlags: callflag.WriteStates, ParamCount: 2}, {Name: interopnames.SystemStorageFind, Func: storageFind, Price: 1 << 15, RequiredFlags: callflag.ReadStates, ParamCount: 3},