From 7afd6dbc74000d3a2dc731fa5db4b259eb7f05cd Mon Sep 17 00:00:00 2001 From: Shivaram Lingamneni Date: Tue, 13 Feb 2024 21:32:37 -0500 Subject: [PATCH] bearer: close open jwt key files --- irc/jwt/bearer.go | 1 + 1 file changed, 1 insertion(+) diff --git a/irc/jwt/bearer.go b/irc/jwt/bearer.go index a9280b0b..4526ae8a 100644 --- a/irc/jwt/bearer.go +++ b/irc/jwt/bearer.go @@ -112,6 +112,7 @@ func (j *JWTAuthTokenConfig) keyBytes() (result []byte, err error) { if err != nil { return nil, err } + defer o.Close() return io.ReadAll(o) } if j.KeyString != "" {