From 440733c1d96249a66e7f5d1bde1fd54770af0d56 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Wed, 3 Apr 2013 18:22:47 +0200 Subject: avoid regexp to check progress --- module/plugins/internal/UnRar.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'module/plugins') diff --git a/module/plugins/internal/UnRar.py b/module/plugins/internal/UnRar.py index ef31fbae2..f11a49854 100644 --- a/module/plugins/internal/UnRar.py +++ b/module/plugins/internal/UnRar.py @@ -22,6 +22,7 @@ import re from os.path import join from glob import glob from subprocess import Popen, PIPE +from string import digits from module.utils import save_join, decode from module.plugins.internal.AbstractExtractor import AbtractExtractor, WrongPassword, ArchiveError, CRCError @@ -129,7 +130,7 @@ class UnRar(AbtractExtractor): progress(int(progressstring)) progressstring = "" # not reading a digit -> therefore restart - elif re.match('[0-9]',c) is None: + elif c not in digits: progressstring = "" # add digit to progressstring else: -- cgit v1.2.3