live-snapshot: fixes snapshotting from resync string.
authorMarco Amadori <marco.amadori@gmail.com>
Fri, 6 Jun 2008 21:03:27 +0000 (23:03 +0200)
committerDaniel Baumann <daniel@debian.org>
Wed, 9 Mar 2011 16:48:00 +0000 (17:48 +0100)
* Now it properly overwrites previous snapshot instead of just
  putting it in the $PWD.

bin/live-snapshot

index dc1fa6d..b523c4a 100755 (executable)
@@ -206,7 +206,7 @@ Defaults ()
        then
                SNAP_COW=$(echo "${SNAP_RESYNC_STRING}" | cut -f1 -d ':')
                SNAP_DEV=$(echo "${SNAP_RESYNC_STRING}" | cut -f2 -d ':')
-               DEST=$(echo "${SNAP_RESYNC_STRING}" | cut -f3 -d ':')
+               DEST="${MOUNTP}/$(echo ${SNAP_RESYNC_STRING} | cut -f3 -d ':')"
 
                case "${DEST}" in
                        *.cpio.gz)