mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-02-17 03:50:42 +03:00
code consistency
This commit is contained in:
parent
515be4ee0b
commit
4727589135
|
@ -58,7 +58,7 @@ class BigArray(list):
|
||||||
return ValueError, "%s is not in list" % value
|
return ValueError, "%s is not in list" % value
|
||||||
|
|
||||||
def _dump(self, value):
|
def _dump(self, value):
|
||||||
handle, filename = tempfile.mkstemp()
|
handle, filename = tempfile.mkstemp(prefix="sqlmapba-")
|
||||||
self.filenames.add(filename)
|
self.filenames.add(filename)
|
||||||
os.close(handle)
|
os.close(handle)
|
||||||
with open(filename, "w+b") as fp:
|
with open(filename, "w+b") as fp:
|
||||||
|
|
|
@ -3380,7 +3380,7 @@ def resetCookieJar(cookieJar):
|
||||||
|
|
||||||
content = readCachedFileContent(conf.loadCookies)
|
content = readCachedFileContent(conf.loadCookies)
|
||||||
lines = filter(None, (line.strip() for line in content.split("\n") if not line.startswith('#')))
|
lines = filter(None, (line.strip() for line in content.split("\n") if not line.startswith('#')))
|
||||||
handle, filename = tempfile.mkstemp()
|
handle, filename = tempfile.mkstemp(prefix="sqlmapcj-")
|
||||||
os.close(handle)
|
os.close(handle)
|
||||||
|
|
||||||
with open(filename, "w+b") as f:
|
with open(filename, "w+b") as f:
|
||||||
|
|
|
@ -467,7 +467,7 @@ def _createTargetDirs():
|
||||||
try:
|
try:
|
||||||
os.makedirs(paths.SQLMAP_OUTPUT_PATH, 0755)
|
os.makedirs(paths.SQLMAP_OUTPUT_PATH, 0755)
|
||||||
except OSError, ex:
|
except OSError, ex:
|
||||||
tempDir = tempfile.mkdtemp(prefix='output')
|
tempDir = tempfile.mkdtemp(prefix="sqlmapoutput")
|
||||||
warnMsg = "unable to create default root output directory "
|
warnMsg = "unable to create default root output directory "
|
||||||
warnMsg += "'%s' (%s). " % (paths.SQLMAP_OUTPUT_PATH, ex)
|
warnMsg += "'%s' (%s). " % (paths.SQLMAP_OUTPUT_PATH, ex)
|
||||||
warnMsg += "using temporary directory '%s' instead" % tempDir
|
warnMsg += "using temporary directory '%s' instead" % tempDir
|
||||||
|
@ -481,7 +481,7 @@ def _createTargetDirs():
|
||||||
try:
|
try:
|
||||||
os.makedirs(conf.outputPath, 0755)
|
os.makedirs(conf.outputPath, 0755)
|
||||||
except OSError, ex:
|
except OSError, ex:
|
||||||
tempDir = tempfile.mkdtemp(prefix='output')
|
tempDir = tempfile.mkdtemp(prefix="sqlmapoutput")
|
||||||
warnMsg = "unable to create output directory "
|
warnMsg = "unable to create output directory "
|
||||||
warnMsg += "'%s' (%s). " % (conf.outputPath, ex)
|
warnMsg += "'%s' (%s). " % (conf.outputPath, ex)
|
||||||
warnMsg += "using temporary directory '%s' instead" % tempDir
|
warnMsg += "using temporary directory '%s' instead" % tempDir
|
||||||
|
|
Loading…
Reference in New Issue
Block a user