From a3bcac5e91dfcc11ff11b170c216d7331c938e6e Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Fri, 2 Sep 2016 14:17:07 +0200 Subject: [PATCH] Revert "Log better errors when locks could not be acquired" This reverts commit 20c4b654ba9a5027f59d7063b5a364ff0f370bd1. --- src/functions/functions.lock | 7 +------ src/udev/network-hotplug-rename | 2 +- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/functions/functions.lock b/src/functions/functions.lock index 99da1f95..b09b0b36 100644 --- a/src/functions/functions.lock +++ b/src/functions/functions.lock @@ -40,12 +40,7 @@ lock_acquire() { sleep 0.25 done - if ! ${free}; then - log ERROR "Could not acquire lock '${lockfile}'" - return ${EXIT_ERROR} - fi - - assert [ ! -e "${lockfile}" ] + assert ${free} "Could not acquire lock '${lockfile}'" # Write out pid to the lockfile and make sure that # nobody else can access it. diff --git a/src/udev/network-hotplug-rename b/src/udev/network-hotplug-rename index 0b500184..c56c70d1 100644 --- a/src/udev/network-hotplug-rename +++ b/src/udev/network-hotplug-rename @@ -45,7 +45,7 @@ log DEBUG "Called for interface '${INTERFACE}'." device_exists ${INTERFACE} || exit ${EXIT_ERROR} # Acquiring lock for this operation. -lock_acquire ${LOCKFILE} || exit ${EXIT_ERROR} +lock_acquire ${LOCKFILE} # Check if the device is already in use and # prevent the script to touch it in any way. -- 2.39.2