Why is this error "dbus: connection closed by user"
Mashiro707 opened this issue · 0 comments
Mashiro707 commented
I want to create a global connection.
so...i tried to use it but there was an error "dbus: connection closed by user"
simple code
err = gosys.NewSystemdConnection()
conn := gosys.GetSystemdConnection()
resChan := make(chan string)
unitID, err := conn.ReloadOrRestartUnitContext(ctx, target, "fail", resChan)
Can you tell me why?thanks~