MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / _dump

Method _dump

lib/core/bigarray.py:186–200  ·  view source on GitHub ↗
(self, chunk)

Source from the content-addressed store, hash-verified

184 self.close()
185
186 def _dump(self, chunk):
187 try:
188 handle, filename = tempfile.mkstemp(prefix=MKSTEMP_PREFIX.BIG_ARRAY)
189 self.filenames.add(filename)
190 os.close(handle)
191 with open(filename, "w+b") as f:
192 f.write(zlib.compress(pickle.dumps(chunk, pickle.HIGHEST_PROTOCOL), BIGARRAY_COMPRESS_LEVEL))
193 return filename
194 except (OSError, IOError) as ex:
195 errMsg = "exception occurred while storing data "
196 errMsg += "to a temporary file ('%s'). Please " % ex
197 errMsg += "make sure that there is enough disk space left. If problem persists, "
198 errMsg += "try to set environment variable 'TEMP' to a location "
199 errMsg += "writeable by the current user"
200 raise SqlmapSystemException(errMsg)
201
202 def _checkcache(self, index):
203 if self.cache is not None and not isinstance(self.cache, Cache):

Callers 3

appendMethod · 0.95
_checkcacheMethod · 0.95
__getstate__Method · 0.95

Calls 4

addMethod · 0.45
closeMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected