Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
go-libp2p
Commits
d104ff8d
Commit
d104ff8d
authored
6 years ago
by
Abhishek Upperwal
Browse files
Options
Download
Email Patches
Plain Diff
making go fmt happy
parent
f82d4ec6
master
2018-Q4-OKR
feat/protobuf
fix/473
fix/no-custom-field
fix/revert-correct-external-addr
multistream-ping
punching
v6.0.23
v6.0.22
v6.0.21
v6.0.20
v6.0.19
v6.0.18
v6.0.17
v6.0.16
v6.0.15
v6.0.14
v6.0.13
v6.0.12
v6.0.11
v6.0.10
v6.0.9
v6.0.8
v6.0.7
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
defaults.go
+3
-2
defaults.go
with
3 additions
and
2 deletions
+3
-2
defaults.go
View file @
d104ff8d
...
...
@@ -21,7 +21,7 @@ import (
// security protocols.
var
DefaultSecurity
=
Security
(
secio
.
ID
,
secio
.
New
)
// DefaultMuxer configures libp2p to use the stream connection multiplexers.
// DefaultMuxer
s
configures libp2p to use the stream connection multiplexers.
//
// Use this option when you want to *extend* the set of multiplexers used by
// libp2p instead of replacing them.
...
...
@@ -53,6 +53,7 @@ var RandomIdentity = func(cfg *Config) error {
return
cfg
.
Apply
(
Identity
(
priv
))
}
// DefaultListenAddrs configures libp2p to use default listen address
var
DefaultListenAddrs
=
func
(
cfg
*
Config
)
error
{
defaultListenAddr
,
err
:=
multiaddr
.
NewMultiaddr
(
"/ip4/0.0.0.0/tcp/0"
)
if
err
!=
nil
{
...
...
@@ -91,7 +92,7 @@ var defaults = []struct {
},
{
fallback
:
func
(
cfg
*
Config
)
bool
{
return
cfg
.
ListenAddrs
==
nil
},
opt
:
DefaultListenAddrs
,
opt
:
DefaultListenAddrs
,
},
}
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Projects
Groups
Snippets
Help