OSDN Git Service

test dead encode killing.
[rec10/rec10-git.git] / rec10 / trunk / src / auto_process.py
index 57f805b..d601b13 100644 (file)
@@ -206,8 +206,9 @@ def killDeadEncode(path):
             tspath=unicode(fn.replace(".264",".ts"),'utf-8')\r
             m2vpath=unicode(fn.replace(".264",".m2v"),'utf-8')\r
             x264path=fn\r
-            x264path=x264path.replace("[^\\]\[","\\\[")\r
-            x264path=x264path.replace("[^\\]\]","\\\]")\r
+            x264path=re.sub("[^\\]\[","\\\[",x264path)\r
+            x264path=re.sub("[^\\]\]","\\\]",x264path)\r
+            #x264path=x264path.replace("[^\\]\]","\\\]")\r
             x264path=unicode(x264path,'utf-8')\r
             os.environ['LANG']="ja_JP.UTF-8"\r
             ktmp=u"ps auxww | grep \""+x264path+u"\" | egrep -v grep | egrep -v \"sh -c\" | grep x264 | awk '{print $2}'"\r