summaryrefslogtreecommitdiffstats
path: root/pyload/plugin/OCR.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2015-02-28 22:34:54 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2015-02-28 22:34:54 +0100
commite9f69e9df0fd1cd484670af180d64caea53eaa5c (patch)
treeb9e39821e948cb8dbe0adf79f9109f010314aef3 /pyload/plugin/OCR.py
parentMerge branch 'stable' into 0.4.10 (diff)
downloadpyload-e9f69e9df0fd1cd484670af180d64caea53eaa5c.tar.xz
safe_join -> fs_join
Diffstat (limited to 'pyload/plugin/OCR.py')
-rw-r--r--pyload/plugin/OCR.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/pyload/plugin/OCR.py b/pyload/plugin/OCR.py
index 73b3a788a..109dd1843 100644
--- a/pyload/plugin/OCR.py
+++ b/pyload/plugin/OCR.py
@@ -14,7 +14,7 @@ import subprocess
#import tempfile
from pyload.plugin.Plugin import Base
-from pyload.utils import safe_join
+from pyload.utils import fs_join
class OCR(Base):
@@ -60,11 +60,11 @@ class OCR(Base):
def run_tesser(self, subset=False, digits=True, lowercase=True, uppercase=True):
#tmpTif = tempfile.NamedTemporaryFile(suffix=".tif")
try:
- tmpTif = open(safe_join("tmp", "tmpTif_%s.tif" % self.__name), "wb")
+ tmpTif = open(fs_join("tmp", "tmpTif_%s.tif" % self.__name), "wb")
tmpTif.close()
#tmpTxt = tempfile.NamedTemporaryFile(suffix=".txt")
- tmpTxt = open(safe_join("tmp", "tmpTxt_%s.txt" % self.__name), "wb")
+ tmpTxt = open(fs_join("tmp", "tmpTxt_%s.txt" % self.__name), "wb")
tmpTxt.close()
except IOError, e:
@@ -83,7 +83,7 @@ class OCR(Base):
if subset and (digits or lowercase or uppercase):
#tmpSub = tempfile.NamedTemporaryFile(suffix=".subset")
- with open(safe_join("tmp", "tmpSub_%s.subset" % self.__name), "wb") as tmpSub:
+ with open(fs_join("tmp", "tmpSub_%s.subset" % self.__name), "wb") as tmpSub:
tmpSub.write("tessedit_char_whitelist ")
if digits: