Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1d07b93

Browse files
committed
Bug fix for --os-shell on MySQL (it was not working for a long time because of this)
1 parent 5358d85 commit 1d07b93

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

lib/core/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1529,7 +1529,7 @@ def getSQLSnippet(dbms, sfile, **variables):
15291529

15301530
retVal = readCachedFileContent(filename)
15311531
retVal = re.sub(r"#.+", "", retVal)
1532-
retVal = re.sub(r"(?s);\s+", "; ", retVal).strip()
1532+
retVal = re.sub(r"(?s);\s+", "; ", retVal).strip("\r\n")
15331533

15341534
for _ in variables.keys():
15351535
retVal = re.sub(r"%%%s%%" % _, variables[_], retVal)

procs/mysql/write_file_limit.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
LIMIT 1 INTO OUTFILE '%OUTFILE%' LINES TERMINATED BY 0x%HEXSTRING% --
1+
LIMIT 1 INTO OUTFILE '%OUTFILE%' LINES TERMINATED BY 0x%HEXSTRING%--

0 commit comments

Comments
 (0)