mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-04 06:50:14 +00:00
Minor patches
This commit is contained in:
parent
4af6dad130
commit
dc30e60082
4 changed files with 12 additions and 8 deletions
|
|
@ -295,7 +295,11 @@ def getBytes(value, encoding=None, errors="strict", unsafe=True):
|
|||
except (LookupError, TypeError):
|
||||
encoding = UNICODE_ENCODING
|
||||
|
||||
if isinstance(value, six.text_type):
|
||||
if isinstance(value, bytearray):
|
||||
return bytes(value)
|
||||
elif isinstance(value, memoryview):
|
||||
return value.tobytes()
|
||||
elif isinstance(value, six.text_type):
|
||||
if INVALID_UNICODE_PRIVATE_AREA:
|
||||
if unsafe:
|
||||
for char in xrange(0xF0000, 0xF00FF + 1):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue