fixin g filename sanitation
This commit is contained in:
parent
d523525eca
commit
e5dcc81930
11
ppss.sh
11
ppss.sh
@ -964,7 +964,16 @@ lock_item () {
|
|||||||
then
|
then
|
||||||
ITEM="$1"
|
ITEM="$1"
|
||||||
|
|
||||||
LOCK_FILE_NAME=`echo "$ITEM" |sed s/^\\\.//g | sed s/^\\\.\\\.//g | sed s/\\\///g | sed s/\\ //g | sed s/\\'/\\\\\\\\\\\\\\'/g | sed s/\&/\\\\\\\\\\\\\\&/g | sed s/\(/\\\\\\\\\\(/g | sed s/\)/\\\\\\\\\\)/g `
|
LOCK_FILE_NAME=`echo "$ITEM" | \
|
||||||
|
sed s/^\\\.//g | \
|
||||||
|
sed s/^\\\.\\\.//g | \
|
||||||
|
sed s/^\\\///g | \
|
||||||
|
sed s/\\\//\\\\\\ /g | \
|
||||||
|
sed s/\\ /\\\\\\\\\\\\\\ /g | \
|
||||||
|
sed s/\\'/\\\\\\\\\\\\\\'/g | \
|
||||||
|
sed s/\&/\\\\\\\\\\\\\\&/g | \
|
||||||
|
sed s/\(/\\\\\\\\\\(/g | \
|
||||||
|
sed s/\)/\\\\\\\\\\)/g `
|
||||||
|
|
||||||
echo " ---> $LOCK_FILE_NAME"
|
echo " ---> $LOCK_FILE_NAME"
|
||||||
ITEM_LOCK_FILE="$ITEM_LOCK_DIR/$LOCK_FILE_NAME"
|
ITEM_LOCK_FILE="$ITEM_LOCK_DIR/$LOCK_FILE_NAME"
|
||||||
|
Loading…
Reference in New Issue
Block a user