aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/system/wayland.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-12-07 00:31:04 +0900
committerOphestra <cat@gensokyo.uk>2025-12-07 00:43:50 +0900
commitd837628b4ca58b4de85c27dbf815decadd4a0903 (patch)
treeb1a52da7dd65a583e93969117e3fc16fdfba8109 /internal/system/wayland.go
parent3cb58b4b72ddb9ae1e354b954ae15230c9a49d6d (diff)
internal/system: remove ineffectual join reverting wayland
Removing the pathname socket used to be handled separately, now it is done during the Close call. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/system/wayland.go')
-rw-r--r--internal/system/wayland.go16
1 files changed, 5 insertions, 11 deletions
diff --git a/internal/system/wayland.go b/internal/system/wayland.go
index 8ce13b66..43112784 100644
--- a/internal/system/wayland.go
+++ b/internal/system/wayland.go
@@ -3,11 +3,11 @@ package system
import (
"errors"
"fmt"
+ "io"
"hakurei.app/container/check"
"hakurei.app/hst"
"hakurei.app/internal/acl"
- "hakurei.app/internal/wayland"
)
// Wayland maintains a wayland socket with security-context-v1 attached via [wayland].
@@ -21,7 +21,7 @@ func (sys *I) Wayland(dst, src *check.Absolute, appID, instanceID string) *I {
// waylandOp implements [I.Wayland].
type waylandOp struct {
- ctx *wayland.SecurityContext
+ ctx io.Closer
dst, src *check.Absolute
appID, instanceID string
}
@@ -53,17 +53,11 @@ func (w *waylandOp) apply(sys *I) (err error) {
}
func (w *waylandOp) revert(sys *I, _ *Criteria) error {
- var (
- hangupErr error
- removeErr error
- )
-
- sys.msg.Verbosef("hanging up wayland socket on %q", w.dst)
if w.ctx != nil {
- hangupErr = w.ctx.Close()
+ sys.msg.Verbosef("hanging up wayland socket on %q", w.dst)
+ return newOpError("wayland", w.ctx.Close(), true)
}
-
- return newOpError("wayland", errors.Join(hangupErr, removeErr), true)
+ return nil
}
func (w *waylandOp) Is(o Op) bool {