From 6016c2d686b6d5f2d9750bfaf2d31945a2680110 Mon Sep 17 00:00:00 2001 From: Javi Fontan Date: Mon, 10 Jun 2013 18:42:48 +0200 Subject: [PATCH] bug #2104: delete unused persistent disk links (cherry picked from commit 13d719a2b391cf8836ae3b264aa51a6819e58a0a) --- src/tm_mad/shared/mvds | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/tm_mad/shared/mvds b/src/tm_mad/shared/mvds index aa34c732aa..221cc3a9ae 100755 --- a/src/tm_mad/shared/mvds +++ b/src/tm_mad/shared/mvds @@ -62,6 +62,7 @@ DST_READLN=\$($READLINK -f $DST_PATH) if [ -d $SRC_PATH ] ; then if [ \( -L $SRC_PATH \) -a \( "\$SRC_READLN" = "\$DST_READLN" \) ] ; then echo "Not moving files to image repo, they are the same" + rm $SRC_PATH elif [ -f $SRC_PATH/.is_persistent ]; then echo "Not moving files to image repo, they are the same" else @@ -69,6 +70,7 @@ if [ -d $SRC_PATH ] ; then fi elif [ \( -L $SRC_PATH \) -a \( "\$SRC_READLN" = "\$DST_READLN" \) ] ; then echo "Not moving files to image repo, they are the same" + rm $SRC_PATH else mv -f $SRC_PATH $DST_PATH fi