mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
Update natupnp.go
This commit is contained in:
parent
5606cbc710
commit
e9797ab867
1 changed files with 1 additions and 1 deletions
|
|
@ -82,7 +82,7 @@ func (n *upnp) ExternalIP() (addr net.IP, err error) {
|
||||||
func (n *upnp) AddMapping(protocol string, extport, intport int, desc string, lifetime time.Duration) (uint16, error) {
|
func (n *upnp) AddMapping(protocol string, extport, intport int, desc string, lifetime time.Duration) (uint16, error) {
|
||||||
ip, err := n.internalAddress()
|
ip, err := n.internalAddress()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, nil // TODO: Shouldn't we return the error?
|
return 0, err
|
||||||
}
|
}
|
||||||
protocol = strings.ToUpper(protocol)
|
protocol = strings.ToUpper(protocol)
|
||||||
lifetimeS := uint32(lifetime / time.Second)
|
lifetimeS := uint32(lifetime / time.Second)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue