mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #23742: ntpath.expandvars() no longer loses unbalanced single quotes.
This commit is contained in:
parent
81f241ab2e
commit
1b87ae0c91
3 changed files with 4 additions and 1 deletions
|
@ -400,7 +400,7 @@ def expandvars(path):
|
|||
index = path.index(c)
|
||||
res += c + path[:index + 1]
|
||||
except ValueError:
|
||||
res += path
|
||||
res += c + path
|
||||
index = pathlen - 1
|
||||
elif c == percent: # variable or '%'
|
||||
if path[index + 1:index + 2] == percent:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue