diff options
Diffstat (limited to 'rule_generator/rule_generator.functions')
-rw-r--r-- | rule_generator/rule_generator.functions | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/rule_generator/rule_generator.functions b/rule_generator/rule_generator.functions index 4bec27a1b7..a6e9c8c4d8 100644 --- a/rule_generator/rule_generator.functions +++ b/rule_generator/rule_generator.functions @@ -48,8 +48,7 @@ writeable() { # Create a lock file for the current rules file. lock_rules_file() { - RUNDIR=$(udevadm info --run) - [ -e "$RUNDIR" ] || return 0 + RUNDIR="/run/udev/" RULES_LOCK="$RUNDIR/.lock-${RULES_FILE##*/}" @@ -72,7 +71,8 @@ unlock_rules_file() { # Choose the real rules file if it is writeable or a temporary file if not. # Both files should be checked later when looking for existing rules. choose_rules_file() { - RUNDIR=$(udevadm info --run) + RUNDIR="/run/udev/" + local tmp_rules_file="$RUNDIR/tmp-rules--${RULES_FILE##*/}" [ -e "$RULES_FILE" -o -e "$tmp_rules_file" ] || PRINT_HEADER=1 |