mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-23 01:56:36 +03:00
Minor just in case update for an Issue #195 (safer behavior on forced charsets)
This commit is contained in:
parent
efe4c13ed1
commit
6bc5f44b20
|
@ -1839,10 +1839,7 @@ def getUnicode(value, encoding=None, system=False, noneToNull=False):
|
||||||
if isinstance(value, unicode):
|
if isinstance(value, unicode):
|
||||||
return value
|
return value
|
||||||
elif isinstance(value, basestring):
|
elif isinstance(value, basestring):
|
||||||
try:
|
return unicode(value, encoding or kb.pageEncoding or UNICODE_ENCODING, "replace")
|
||||||
return unicode(value, encoding or kb.pageEncoding)
|
|
||||||
except:
|
|
||||||
return unicode(value, UNICODE_ENCODING, "replace")
|
|
||||||
else:
|
else:
|
||||||
return unicode(value) # encoding ignored for non-basestring instances
|
return unicode(value) # encoding ignored for non-basestring instances
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user