Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
p2p
go-p2p-swarm
Commits
bfd797c3
Commit
bfd797c3
authored
Oct 24, 2016
by
Jeromy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
expose errors in log messages
parent
40ba0294
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
swarm_dial.go
swarm_dial.go
+2
-2
No files found.
swarm_dial.go
View file @
bfd797c3
...
...
@@ -266,7 +266,7 @@ func (s *Swarm) dial(ctx context.Context, p peer.ID) (*Conn, error) {
// try to get a connection to any addr
connC
,
err
:=
s
.
dialAddrs
(
ctx
,
p
,
remoteAddrChan
)
if
err
!=
nil
{
logdial
[
"error"
]
=
err
logdial
[
"error"
]
=
err
.
Error
()
return
nil
,
err
}
logdial
[
"netconn"
]
=
lgbl
.
NetConn
(
connC
)
...
...
@@ -275,7 +275,7 @@ func (s *Swarm) dial(ctx context.Context, p peer.ID) (*Conn, error) {
defer
log
.
EventBegin
(
ctx
,
"swarmDialDoSetup"
,
logdial
,
lgbl
.
NetConn
(
connC
))
.
Done
()
swarmC
,
err
:=
dialConnSetup
(
ctx
,
s
,
connC
)
if
err
!=
nil
{
logdial
[
"error"
]
=
err
logdial
[
"error"
]
=
err
.
Error
()
connC
.
Close
()
// close the connection. didn't work out :(
return
nil
,
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