mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-29 21:13:51 +03:00
Minor adjustment
This commit is contained in:
parent
050015d2bb
commit
319adef8c4
|
@ -1114,11 +1114,10 @@ def profile(profileOutputFile=None, imageOutputFile=None):
|
||||||
|
|
||||||
graphScriptPath = os.path.join(paths.SQLMAP_EXTRAS_PATH, 'gprof2dot', 'gprof2dot.py')
|
graphScriptPath = os.path.join(paths.SQLMAP_EXTRAS_PATH, 'gprof2dot', 'gprof2dot.py')
|
||||||
process = execute('%s %s -f pstats %s | dot -Tpng -o %s' % (sys.executable, graphScriptPath, profileOutputFile, imageOutputFile), shell=True, stdout=None, stderr=PIPE)
|
process = execute('%s %s -f pstats %s | dot -Tpng -o %s' % (sys.executable, graphScriptPath, profileOutputFile, imageOutputFile), shell=True, stdout=None, stderr=PIPE)
|
||||||
pollProcess(process)
|
processStderr = process.communicate()[1]
|
||||||
payloadStderr = process.communicate()[1]
|
|
||||||
|
|
||||||
if payloadStderr or not os.path.exists(imageOutputFile):
|
if processStderr or not os.path.exists(imageOutputFile):
|
||||||
errMsg = "there was an error while converting ('%s'), " % payloadStderr.strip()
|
errMsg = "there was an error while converting ('%s'), " % processStderr.strip()
|
||||||
errMsg += "but you can still find raw profile data "
|
errMsg += "but you can still find raw profile data "
|
||||||
errMsg += "inside file '%s'" % profileOutputFile
|
errMsg += "inside file '%s'" % profileOutputFile
|
||||||
logger.error(errMsg)
|
logger.error(errMsg)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user