]> git.ipfire.org Git - thirdparty/wireguard-go.git/commitdiff
Prettier abbreviation
authorJason A. Donenfeld <Jason@zx2c4.com>
Sun, 13 May 2018 21:27:28 +0000 (23:27 +0200)
committerJason A. Donenfeld <Jason@zx2c4.com>
Sun, 13 May 2018 21:27:28 +0000 (23:27 +0200)
peer.go

diff --git a/peer.go b/peer.go
index 1151341bb79ccc74f6c0da1472b59a491c224a1d..954c69c1a47e39a3e50987d41ba727661979a3d0 100644 (file)
--- a/peer.go
+++ b/peer.go
@@ -147,7 +147,7 @@ func (peer *Peer) String() string {
        base64Key := base64.StdEncoding.EncodeToString(peer.handshake.remoteStatic[:])
        abbreviatedKey := "invalid"
        if len(base64Key) == 44 {
-               abbreviatedKey = base64Key[0:4] + "..." + base64Key[40:44]
+               abbreviatedKey = base64Key[0:4] + "…" + base64Key[39:43]
        }
        return fmt.Sprintf("peer(%s)", abbreviatedKey)
 }