From b24d8d1e2c5f594266f84a78ea9205156488d57c Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Mon, 28 Nov 2022 15:38:59 +0100 Subject: [PATCH] main.go: check return error from shClient.SendCloseMessage() --- main.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main.go b/main.go index 41fa9d1..7ba1d85 100644 --- a/main.go +++ b/main.go @@ -118,7 +118,10 @@ func run() { // Cleanly close the connection by sending a close message and then // waiting (with timeout) for the server to close the connection. - shClient.SendCloseMessage() + err := shClient.SendCloseMessage() + if err != nil { + log.Println("failed to send close message to ship server", err) + } select { case <-done: