forked from security/hakurei
internal/pipewire: constant for PIPEWIRE_REMOTE
This is not defined anywhere in upstream PipeWire, no idea why. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -783,6 +783,9 @@ func (ctx *Context) Close() (err error) {
|
||||
}
|
||||
}
|
||||
|
||||
// Remote is the environment (sic) with the remote name.
|
||||
const Remote = "PIPEWIRE_REMOTE"
|
||||
|
||||
/* modules/module-protocol-native/local-socket.c */
|
||||
|
||||
const DEFAULT_SYSTEM_RUNTIME_DIR = "/run/pipewire"
|
||||
@@ -821,7 +824,7 @@ func ConnectName(name string, manager bool) (ctx *Context, err error) {
|
||||
}
|
||||
|
||||
if name == "" {
|
||||
if v, ok := os.LookupEnv("PIPEWIRE_REMOTE"); !ok || v == "" {
|
||||
if v, ok := os.LookupEnv(Remote); !ok || v == "" {
|
||||
name = PW_DEFAULT_REMOTE
|
||||
} else {
|
||||
name = v
|
||||
|
||||
Reference in New Issue
Block a user