From 6fa45a96bf639a42baac3932547981e64d247d0f Mon Sep 17 00:00:00 2001 From: gn64_jp Date: Mon, 22 Mar 2010 12:22:36 +0000 Subject: [PATCH] fix mp4 auto-del. git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/rec10@501 4e526526-5e11-4fc0-8910-f8fd03428081 --- rec10/trunk/src/tv2mp4.py | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/rec10/trunk/src/tv2mp4.py b/rec10/trunk/src/tv2mp4.py index 1f18a52..6d63a58 100644 --- a/rec10/trunk/src/tv2mp4.py +++ b/rec10/trunk/src/tv2mp4.py @@ -147,15 +147,10 @@ def mkv2mp4(pin,pout): recdblist.addlog(pin, txt, "MKV2MP4-log") txt = "\n####MKV2MP4-log####\n"+txt time.sleep(10) - if os.path.exists(pout): - if os.path.exists(audiopath): - os.remove(audiopath) - if os.path.exists(videopath): - os.remove(videopath) - if os.path.exists(timecodepath): - os.remove(timecodepath) - if os.path.exists(tmpmp4): - os.remove(tmpmp4) + if status.getSettings_auto_del_tmp()==1: + if os.path.exists(pout): + if os.path.getsize(pout)>100*1000*1000: + deltitle(dir,title) def execmp4box(pin,pout,cmd): title=os.path.splitext(os.path.split(pin)[1])[0] ptin=os.path.join(os.path.dirname(pin),base64.b16encode(title.encode('utf-8'))+".264") -- 2.11.0