mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-04 14:55:40 +00:00
Minor adjustments
This commit is contained in:
parent
0a378c1078
commit
9fcab68700
4 changed files with 20 additions and 15 deletions
|
|
@ -1437,12 +1437,13 @@ def getUnicode(value, encoding=None):
|
|||
>>> getUnicode(1)
|
||||
u'1'
|
||||
"""
|
||||
|
||||
if encoding is None:
|
||||
encoding = conf.dataEncoding if 'dataEncoding' in conf else "utf-8"
|
||||
if isinstance(value, basestring):
|
||||
return value if isinstance(value, unicode) else unicode(value, encoding, errors='replace')
|
||||
else:
|
||||
return unicode(value) #encoding ignored for non-basestring instances
|
||||
return unicode(value) # encoding ignored for non-basestring instances
|
||||
|
||||
# http://boredzo.org/blog/archives/2007-01-06/longest-common-prefix-in-python-2
|
||||
def longestCommonPrefix(*sequences):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue