locking file name is now always md5 hash

This commit is contained in:
louwrentius 2012-01-29 22:04:40 +00:00
parent a33f87d0b0
commit 8fe6ca64db
1 changed files with 1 additions and 6 deletions

7
ppss
View File

@ -1722,12 +1722,7 @@ lock_item () {
else
ITEM="$1"
if [[ "$USE_MD5" == "1" ]]
then
LOCK_FILE_NAME=$(echo "$ITEM" | $MD5 | awk '{ print $1 }')
else
LOCK_FILE_NAME=$(echo "$ITEM" | sed s/[^[:alnum:]]/_/g)
fi
LOCK_FILE_NAME=$(echo "$ITEM" | $MD5 | awk '{ print $1 }')
ITEM_LOCK_FILE="$ITEM_LOCK_DIR/$LOCK_FILE_NAME"
log DEBUG "Locking item $ITEM_LOCK_FILE"
exec_cmd "mkdir $ITEM_LOCK_FILE >> /dev/null 2>&1"