From fbc025869bd2c2f1355f8581f5944ab4bd6f3f61 Mon Sep 17 00:00:00 2001 From: Darien Raymond Date: Thu, 8 Mar 2018 21:21:50 +0100 Subject: [PATCH] fix lint errors --- app/commander/outbound.go | 2 -- common/protocol/address.go | 6 ++---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/app/commander/outbound.go b/app/commander/outbound.go index 92be34a9..19b90010 100644 --- a/app/commander/outbound.go +++ b/app/commander/outbound.go @@ -76,8 +76,6 @@ func (co *CommanderOutbound) Dispatch(ctx context.Context, r ray.OutboundRay) { co.listener.add(c) co.access.RUnlock() <-closeSignal.Wait() - - return } func (co *CommanderOutbound) Tag() string { diff --git a/common/protocol/address.go b/common/protocol/address.go index bdd2a208..f7d32220 100644 --- a/common/protocol/address.go +++ b/common/protocol/address.go @@ -150,10 +150,8 @@ func (p *AddressParser) ReadAddressPort(buffer *buf.Buffer, input io.Reader) (ne } func (p *AddressParser) writePort(writer io.Writer, port net.Port) error { - if _, err := writer.Write(port.Bytes(nil)); err != nil { - return err - } - return nil + _, err := writer.Write(port.Bytes(nil)) + return err } func (p *AddressParser) writeAddress(writer io.Writer, address net.Address) error {