aboutsummaryrefslogtreecommitdiffhomepage
path: root/dbus/dbus.go
diff options
context:
space:
mode:
authorOphestra Umiker <cat@ophivana.moe>2024-09-25 01:17:38 +0900
committerOphestra Umiker <cat@ophivana.moe>2024-09-25 01:17:38 +0900
commita8b4b3634b8bef6040601d970a7c178da72b114d (patch)
tree4bd8a012f67dcf854fc6593caec6504262d0f436 /dbus/dbus.go
parent97bab6c4061e15c64170d3dca29eadce9841a9d5 (diff)
dbus: use generalised helper.Helper for xdg-dbus-proxy
Signed-off-by: Ophestra Umiker <cat@ophivana.moe>
Diffstat (limited to 'dbus/dbus.go')
-rw-r--r--dbus/dbus.go15
1 files changed, 3 insertions, 12 deletions
diff --git a/dbus/dbus.go b/dbus/dbus.go
index 9c99a703..d68dcfa1 100644
--- a/dbus/dbus.go
+++ b/dbus/dbus.go
@@ -4,8 +4,6 @@ import (
"errors"
"fmt"
"io"
- "os"
- "os/exec"
"sync"
"git.ophivana.moe/cat/fortify/helper"
@@ -14,19 +12,12 @@ import (
// Proxy holds references to a xdg-dbus-proxy process, and should never be copied.
// Once sealed, configuration changes will no longer be possible and attempting to do so will result in a panic.
type Proxy struct {
- cmd *exec.Cmd
-
- statP [2]*os.File
- argsP [2]*os.File
+ helper *helper.Helper
path string
session [2]string
system [2]string
- wait *chan error
- read *chan error
- ready *chan bool
-
seal io.WriterTo
lock sync.RWMutex
}
@@ -39,8 +30,8 @@ func (p *Proxy) String() string {
p.lock.RLock()
defer p.lock.RUnlock()
- if p.cmd != nil {
- return p.cmd.String()
+ if p.helper != nil {
+ return p.helper.String()
}
if p.seal != nil {