mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-03 22:31:34 +00:00
Fixes #4020
This commit is contained in:
parent
f947c5f76e
commit
20d875a8ce
4 changed files with 10 additions and 4 deletions
|
|
@ -231,6 +231,11 @@ def getBytes(value, encoding=UNICODE_ENCODING, errors="strict", unsafe=True):
|
|||
|
||||
retVal = value
|
||||
|
||||
try:
|
||||
codecs.lookup(encoding)
|
||||
except LookupError:
|
||||
encoding = UNICODE_ENCODING
|
||||
|
||||
if isinstance(value, six.text_type):
|
||||
if INVALID_UNICODE_PRIVATE_AREA:
|
||||
if unsafe:
|
||||
|
|
@ -391,4 +396,4 @@ def getConsoleLength(value):
|
|||
else:
|
||||
retVal = len(value)
|
||||
|
||||
return retVal
|
||||
return retVal
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue