Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
c7ee9844
Commit
c7ee9844
authored
Aug 14, 2014
by
obscuren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed old code
parent
0fcc6065
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
7 deletions
+12
-7
state_manager.go
ethchain/state_manager.go
+10
-6
manifest.go
ethstate/manifest.go
+2
-1
No files found.
ethchain/state_manager.go
View file @
c7ee9844
...
@@ -380,14 +380,18 @@ func (sm *StateManager) createBloomFilter(state *ethstate.State) *BloomFilter {
...
@@ -380,14 +380,18 @@ func (sm *StateManager) createBloomFilter(state *ethstate.State) *BloomFilter {
sm
.
Ethereum
.
Reactor
()
.
Post
(
"object:"
+
addr
,
stateObject
)
sm
.
Ethereum
.
Reactor
()
.
Post
(
"object:"
+
addr
,
stateObject
)
}
}
for
stateObjectAddr
,
mappedObjects
:=
range
state
.
Manifest
()
.
StorageChanges
{
sm
.
Ethereum
.
Reactor
()
.
Post
(
"messages"
,
state
.
Manifest
()
.
Messages
)
for
addr
,
value
:=
range
mappedObjects
{
// Set the bloom filter's bin
bloomf
.
Set
(
ethcrypto
.
Sha3Bin
([]
byte
(
stateObjectAddr
+
addr
)))
sm
.
Ethereum
.
Reactor
()
.
Post
(
"storage:"
+
stateObjectAddr
+
":"
+
addr
,
&
ethstate
.
StorageState
{[]
byte
(
stateObjectAddr
),
[]
byte
(
addr
),
value
})
/*
for stateObjectAddr, mappedObjects := range state.Manifest().StorageChanges {
for addr, value := range mappedObjects {
// Set the bloom filter's bin
bloomf.Set(ethcrypto.Sha3Bin([]byte(stateObjectAddr + addr)))
sm.Ethereum.Reactor().Post("storage:"+stateObjectAddr+":"+addr, ðstate.StorageState{[]byte(stateObjectAddr), []byte(addr), value})
}
}
}
}
*/
return
bloomf
return
bloomf
}
}
...
...
ethstate/manifest.go
View file @
c7ee9844
...
@@ -17,7 +17,7 @@ type Manifest struct {
...
@@ -17,7 +17,7 @@ type Manifest struct {
ObjectChanges
map
[
string
]
*
StateObject
ObjectChanges
map
[
string
]
*
StateObject
StorageChanges
map
[
string
]
map
[
string
]
*
big
.
Int
StorageChanges
map
[
string
]
map
[
string
]
*
big
.
Int
Messages
[]
*
Message
Messages
Messages
}
}
func
NewManifest
()
*
Manifest
{
func
NewManifest
()
*
Manifest
{
...
@@ -50,6 +50,7 @@ func (self *Manifest) AddMessage(msg *Message) *Message {
...
@@ -50,6 +50,7 @@ func (self *Manifest) AddMessage(msg *Message) *Message {
return
msg
return
msg
}
}
type
Messages
[]
*
Message
type
Message
struct
{
type
Message
struct
{
To
,
From
[]
byte
To
,
From
[]
byte
Input
[]
byte
Input
[]
byte
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment