mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-03 22:31:34 +00:00
Fixes #6022
This commit is contained in:
parent
959ba63f78
commit
c2f86976fb
3 changed files with 10 additions and 6 deletions
|
|
@ -20,7 +20,7 @@ from lib.core.enums import OS
|
|||
from thirdparty import six
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.10.2.17"
|
||||
VERSION = "1.10.2.18"
|
||||
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
|
||||
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
|
||||
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)
|
||||
|
|
|
|||
|
|
@ -144,9 +144,13 @@ class HashDB(object):
|
|||
if key:
|
||||
hash_ = HashDB.hashKey(key)
|
||||
with self._cache_lock:
|
||||
self._write_cache[hash_] = self._read_cache[hash_] = getUnicode(value) if not serialize else serializeObject(value)
|
||||
cache_size = len(self._write_cache)
|
||||
time_since_flush = time.time() - self._last_flush_time
|
||||
try:
|
||||
self._write_cache[hash_] = self._read_cache[hash_] = getUnicode(value) if not serialize else serializeObject(value)
|
||||
except RecursionError:
|
||||
pass
|
||||
finally:
|
||||
cache_size = len(self._write_cache)
|
||||
time_since_flush = time.time() - self._last_flush_time
|
||||
|
||||
if cache_size >= HASHDB_FLUSH_THRESHOLD_ITEMS or time_since_flush >= HASHDB_FLUSH_THRESHOLD_TIME:
|
||||
self.flush()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue