Skip to content

Commit

Permalink
util, GetRuntimeDir: don't error out early if XDG_RUNTIME_DIR is not …
Browse files Browse the repository at this point in the history
…found

We must try out all possible alternatives for rootless users instead of
failing eary if XDG_RUNTIME_DIR is not set.

Following regression was part of: 48f90f5

[NO NEW TESTS NEEDED]
[NO TESTS NEEDED]

Signed-off-by: Aditya R <arajan@redhat.com>
  • Loading branch information
flouthoc committed Sep 29, 2022
1 parent 8e7519d commit 9bd5c94
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pkg/util/util_supported.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ func GetRuntimeDir() (string, error) {
rootlessRuntimeDirOnce.Do(func() {
runtimeDir, err := homedir.GetRuntimeDir()
if err != nil {
rootlessRuntimeDirError = err
return
logrus.Debug(err)
}
if runtimeDir != "" {
st, err := os.Stat(runtimeDir)
Expand Down

0 comments on commit 9bd5c94

Please sign in to comment.