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
a61e6788
Commit
a61e6788
authored
May 21, 2015
by
Bas van Kervel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
prefix dapp key/value entries in extradb
parent
90b672f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
xeth.go
xeth/xeth.go
+5
-2
No files found.
xeth/xeth.go
View file @
a61e6788
...
@@ -28,6 +28,7 @@ var (
...
@@ -28,6 +28,7 @@ var (
filterTickerTime
=
5
*
time
.
Minute
filterTickerTime
=
5
*
time
.
Minute
defaultGasPrice
=
big
.
NewInt
(
10000000000000
)
//150000000000
defaultGasPrice
=
big
.
NewInt
(
10000000000000
)
//150000000000
defaultGas
=
big
.
NewInt
(
90000
)
//500000
defaultGas
=
big
.
NewInt
(
90000
)
//500000
dappStorePre
=
[]
byte
(
"dapp-"
)
)
)
// byte will be inferred
// byte will be inferred
...
@@ -410,13 +411,15 @@ func (self *XEth) SetSolc(solcPath string) (*compiler.Solidity, error) {
...
@@ -410,13 +411,15 @@ func (self *XEth) SetSolc(solcPath string) (*compiler.Solidity, error) {
return
self
.
Solc
()
return
self
.
Solc
()
}
}
// store DApp value in extra database
func
(
self
*
XEth
)
DbPut
(
key
,
val
[]
byte
)
bool
{
func
(
self
*
XEth
)
DbPut
(
key
,
val
[]
byte
)
bool
{
self
.
backend
.
ExtraDb
()
.
Put
(
key
,
val
)
self
.
backend
.
ExtraDb
()
.
Put
(
append
(
dappStorePre
,
key
...
)
,
val
)
return
true
return
true
}
}
// retrieve DApp value from extra database
func
(
self
*
XEth
)
DbGet
(
key
[]
byte
)
([]
byte
,
error
)
{
func
(
self
*
XEth
)
DbGet
(
key
[]
byte
)
([]
byte
,
error
)
{
val
,
err
:=
self
.
backend
.
ExtraDb
()
.
Get
(
key
)
val
,
err
:=
self
.
backend
.
ExtraDb
()
.
Get
(
append
(
dappStorePre
,
key
...
)
)
return
val
,
err
return
val
,
err
}
}
...
...
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