Add explicit left anchor to directory check regex.

This commit is contained in:
George Edward Bulmer 2017-12-12 13:25:35 +00:00
parent 3cf4e8ba67
commit b07a4c8c28

View File

@ -180,7 +180,7 @@ def transform_path(path):
path = utils.expand_windows_drive(path)
# Drive dependent working directories are not supported, e.g.
# E:filename is invalid
if re.fullmatch(r'[A-Z]:[^\\]', path, re.IGNORECASE):
if re.search(r'^[A-Z]:[^\\]', path, re.IGNORECASE):
return None
# Paths like COM1, ...
# See https://github.com/qutebrowser/qutebrowser/issues/82