Patch by Fatih.
BUG:FIXED:8612
This commit is contained in:
+4
-1
@@ -20,6 +20,7 @@ import sys
|
|||||||
import sha
|
import sha
|
||||||
import shutil
|
import shutil
|
||||||
import string
|
import string
|
||||||
|
import fnmatch
|
||||||
import statvfs
|
import statvfs
|
||||||
import operator
|
import operator
|
||||||
import subprocess
|
import subprocess
|
||||||
@@ -349,8 +350,10 @@ def get_file_hashes(top, excludePrefix=None, removePrefix=None):
|
|||||||
def is_included(path):
|
def is_included(path):
|
||||||
if excludePrefix:
|
if excludePrefix:
|
||||||
temp = remove_prefix(removePrefix, path)
|
temp = remove_prefix(removePrefix, path)
|
||||||
if len(filter(lambda x: temp.startswith(x), excludePrefix)) > 0:
|
while temp != "/":
|
||||||
|
if len(filter(lambda x: fnmatch.fnmatch(temp, x), excludePrefix)) > 0:
|
||||||
return False
|
return False
|
||||||
|
temp = os.path.dirname(temp)
|
||||||
return True
|
return True
|
||||||
|
|
||||||
# single file/symlink case
|
# single file/symlink case
|
||||||
|
|||||||
Reference in New Issue
Block a user