mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 15:32:23 -04:00
don't allow files named . or ..
This commit is contained in:
parent
2ec399a009
commit
3c36ddfb82
1 changed files with 2 additions and 0 deletions
|
@ -360,6 +360,8 @@ def invalidFilename(str, dirsep=True):
|
|||
return "/"
|
||||
elif (dirsep or not isWin) and "\\" in str:
|
||||
return "\\"
|
||||
elif str.strip().startswith("."):
|
||||
return "."
|
||||
|
||||
def platDesc():
|
||||
# we may get an interrupted system call, so try this in a loop
|
||||
|
|
Loading…
Reference in a new issue