From 036b612bcb5cf9783318d51e249605b49211fc21 Mon Sep 17 00:00:00 2001 From: Bernardo Damele Date: Mon, 14 Jan 2013 01:11:42 +0000 Subject: [PATCH] bug fix to be able to write unicode chars to debug file --- lib/core/testing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/core/testing.py b/lib/core/testing.py index 2dc155af7..b17dac619 100644 --- a/lib/core/testing.py +++ b/lib/core/testing.py @@ -172,7 +172,7 @@ def liveTest(): errMsg = "test failed " if failedItem: errMsg += "at parsing item: %s - scan folder is %s" % (failedItem, paths.SQLMAP_OUTPUT_PATH) - console_output_fd = open("%s%sconsole_output" % (paths.SQLMAP_OUTPUT_PATH, os.sep), "wb") + console_output_fd = codecs.open("%s%sconsole_output" % (paths.SQLMAP_OUTPUT_PATH, os.sep), "wb", UNICODE_ENCODING) console_output_fd.write(failedParseOn) console_output_fd.close()