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
1c4c71dc
Commit
1c4c71dc
authored
Mar 24, 2015
by
zelig
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cli: fix liner not closing (spuriously opened) in noninteractive jsre
parent
fd8d18ec
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
js.go
cmd/ethereum/js.go
+2
-2
main.go
cmd/ethereum/main.go
+2
-2
No files found.
cmd/ethereum/js.go
View file @
1c4c71dc
...
...
@@ -67,14 +67,14 @@ type jsre struct {
prompter
}
func
newJSRE
(
ethereum
*
eth
.
Ethereum
,
libPath
string
)
*
jsre
{
func
newJSRE
(
ethereum
*
eth
.
Ethereum
,
libPath
string
,
interactive
bool
)
*
jsre
{
js
:=
&
jsre
{
ethereum
:
ethereum
,
ps1
:
"> "
}
js
.
xeth
=
xeth
.
New
(
ethereum
,
js
)
js
.
re
=
re
.
New
(
libPath
)
js
.
apiBindings
()
js
.
adminBindings
()
if
!
liner
.
TerminalSupported
()
{
if
!
liner
.
TerminalSupported
()
||
!
interactive
{
js
.
prompter
=
dumbterm
{
bufio
.
NewReader
(
os
.
Stdin
)}
}
else
{
lr
:=
liner
.
NewLiner
()
...
...
cmd/ethereum/main.go
View file @
1c4c71dc
...
...
@@ -246,7 +246,7 @@ func console(ctx *cli.Context) {
}
startEth
(
ctx
,
ethereum
)
repl
:=
newJSRE
(
ethereum
,
ctx
.
String
(
utils
.
JSpathFlag
.
Name
))
repl
:=
newJSRE
(
ethereum
,
ctx
.
String
(
utils
.
JSpathFlag
.
Name
)
,
true
)
repl
.
interactive
()
ethereum
.
Stop
()
...
...
@@ -261,7 +261,7 @@ func execJSFiles(ctx *cli.Context) {
}
startEth
(
ctx
,
ethereum
)
repl
:=
newJSRE
(
ethereum
,
ctx
.
String
(
utils
.
JSpathFlag
.
Name
))
repl
:=
newJSRE
(
ethereum
,
ctx
.
String
(
utils
.
JSpathFlag
.
Name
)
,
false
)
for
_
,
file
:=
range
ctx
.
Args
()
{
repl
.
exec
(
file
)
}
...
...
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