diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2020-07-08 11:51:48 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2020-07-13 22:23:44 +0200 |
commit | bd96a6f7b7eb103f97bcd6eadc21908187e94dce (patch) | |
tree | c4ace9ff4cab817915c9b00496a79e83ea2f7a34 /bin/symbolstore.py | |
parent | tdf#134755 Update locale data for Kazakh [kk-KZ] (diff) | |
download | core-bd96a6f7b7eb103f97bcd6eadc21908187e94dce.tar.gz core-bd96a6f7b7eb103f97bcd6eadc21908187e94dce.zip |
Don't rely on Python's treatment of unrecognized escape sequences
According to [1]:
> Changed in version 3.6: Unrecognized escape sequences produce a DeprecationWarning.
> In a future Python version they will be a SyntaxWarning and eventually a SyntaxError.
[1] https://docs.python.org/3/reference/lexical_analysis.html#string-and-bytes-literals
Change-Id: Ia4f79f17ccb121f423f35b1e1306d5ae285e8762
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98321
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'bin/symbolstore.py')
-rwxr-xr-x | bin/symbolstore.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/symbolstore.py b/bin/symbolstore.py index 7ddd8d2ac234..1f80e2f69e99 100755 --- a/bin/symbolstore.py +++ b/bin/symbolstore.py @@ -316,7 +316,7 @@ def SourceIndex(fileStream, outputPath, cvs_root): pdbStreamFile = open(outputPath, "w") pdbStreamFile.write('''SRCSRV: ini ------------------------------------------------\r\nVERSION=1\r\nSRCSRV: variables ------------------------------------------\r\nCVS_EXTRACT_CMD=%fnchdir%(%targ%)cvs.exe -d %fnvar%(%var2%) checkout -r %var4% -d %var4% -N %var3%\r\nMYSERVER=''') pdbStreamFile.write(cvs_root) - pdbStreamFile.write('''\r\nSRCSRVTRG=%targ%\%var4%\%fnbksl%(%var3%)\r\nSRCSRVCMD=%CVS_EXTRACT_CMD%\r\nSRCSRV: source files ---------------------------------------\r\n''') + pdbStreamFile.write('''\r\nSRCSRVTRG=%targ%\\%var4%\\%fnbksl%(%var3%)\r\nSRCSRVCMD=%CVS_EXTRACT_CMD%\r\nSRCSRV: source files ---------------------------------------\r\n''') pdbStreamFile.write(fileStream) # can't do string interpolation because the source server also uses this and so there are % in the above pdbStreamFile.write("SRCSRV: end ------------------------------------------------\r\n\n") pdbStreamFile.close() @@ -417,7 +417,7 @@ class Dumper: # MODULE os cpu guid debug_file (guid, debug_file) = (module_line.split())[3:5] # strip off .pdb extensions, and append .sym - sym_file = re.sub("\.pdb$", "", debug_file) + ".sym" + sym_file = re.sub(r"\.pdb$", "", debug_file) + ".sym" # we do want forward slashes here rel_path = os.path.join(debug_file, guid, |