if ! cmp $md5sum $img.md5sum; then
echo "md5sum check FAILED" >> $logfile
echo "dd if=$dev bs=1M count=$imagesizemb 2>>$logfile | md5sum | awk '{print\$1}' > $md5sum" >> $logfile
- e2label $dev >> $logfile
+ e2label $dev >> $logfile 2>&1
cat $logfile | grep -v -e '[\b\r]' | mailx -s "DVD md5sum doesn't match image file!!!" $mailto
exit 1
fi
cat $img.stat
echo
cat $logfile
-} | grep -v -e '[\b\r]' | mailx -s "DVD burned. File as $(basename ${img%.*})" $mailto > $logfile 2>&1
+} | grep -v -e '[\b\r]' | mailx -s "DVD burned. File as $(basename ${img%.*})" $mailto >> $logfile 2>&1
# Two lines in the stat file indicate two successful burns. Clean-up the image.
if [ "$(wc -l $img.stat 2>/dev/null | awk '{print$1}')" == "$makeXcopies" ]; then