]> git.ipfire.org Git - thirdparty/wireguard-go.git/commitdiff
device: add missing colon to error line
authorJason A. Donenfeld <Jason@zx2c4.com>
Fri, 18 Dec 2020 10:52:13 +0000 (11:52 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Fri, 18 Dec 2020 19:18:47 +0000 (20:18 +0100)
People are actually hitting this condition, so make it uniform. Also,
change a printf into a println, to match the other conventions.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
device/device.go
device/send.go

index e7d70c4e1a0583ae3b894c58fa1583d23629dbfa..5f128fc402ebde83dc51de05f16ff861e69185ef 100644 (file)
@@ -158,7 +158,7 @@ func deviceUpdateState(device *Device) {
        switch newIsUp {
        case true:
                if err := device.BindUpdate(); err != nil {
-                       device.log.Error.Printf("Unable to update bind: %v\n", err)
+                       device.log.Error.Println("Unable to update bind:", err)
                        device.isUp.Set(false)
                        break
                }
index bc51fa6ba99ffd89fc41fdb0ba13e1656ca8eb68..c75d23e6de743e74490af02062c10b95d0247b65 100644 (file)
@@ -174,7 +174,7 @@ func (peer *Peer) SendHandshakeInitiation(isRetry bool) error {
 
        err = peer.SendBuffer(packet)
        if err != nil {
-               peer.device.log.Error.Println(peer, "- Failed to send handshake initiation", err)
+               peer.device.log.Error.Println(peer, "- Failed to send handshake initiation:", err)
        }
        peer.timersHandshakeInitiated()
 
@@ -212,7 +212,7 @@ func (peer *Peer) SendHandshakeResponse() error {
 
        err = peer.SendBuffer(packet)
        if err != nil {
-               peer.device.log.Error.Println(peer, "- Failed to send handshake response", err)
+               peer.device.log.Error.Println(peer, "- Failed to send handshake response:", err)
        }
        return err
 }