aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--internal/wayland/conn.go4
1 files changed, 1 insertions, 3 deletions
diff --git a/internal/wayland/conn.go b/internal/wayland/conn.go
index 4a4428b5..fa7ced8c 100644
--- a/internal/wayland/conn.go
+++ b/internal/wayland/conn.go
@@ -51,10 +51,8 @@ func New(displayPath, bindPath *check.Absolute, appID, instanceID string) (*Secu
} else {
closeFds, bindErr := securityContextBindPipe(fd, bindPath, appID, instanceID)
if bindErr != nil {
- // do not leak the pipe and socket
err = errors.Join(bindErr, // already wrapped
- syscall.Close(closeFds[1]),
- syscall.Close(closeFds[0]),
+ // do not leak the socket
syscall.Close(fd),
)
}