mirror of
https://github.com/samba-team/samba.git
synced 2025-12-21 20:23:50 +03:00
samba-tool: Don't use invalid escape sequences
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
committed by
Andrew Bartlett
parent
65ab33dffa
commit
1312b2d169
@@ -1651,7 +1651,7 @@ class cmd_restore(cmd_create):
|
||||
entities_content = entities_file.read()
|
||||
|
||||
# Do a basic regex test of the entities file format
|
||||
if re.match('(\s*<!ENTITY\s*[a-zA-Z0-9_]+\s*.*?>)+\s*\Z',
|
||||
if re.match(r'(\s*<!ENTITY\s*[a-zA-Z0-9_]+\s*.*?>)+\s*\Z',
|
||||
entities_content, flags=re.MULTILINE) is None:
|
||||
raise CommandError("Entities file does not appear to "
|
||||
"conform to format\n"
|
||||
|
||||
Reference in New Issue
Block a user