Closed GoogleCodeExporter closed 9 years ago
It may be due to the pefile.PE instance not being destroyed immediately and
still keeping the file open. I'd suggest trying to force Python to free the
object:
pe = pefile.PE(SrcPath, fast_load = True)
del pe
With a bit of luck that releases the file. You could also try to directly close
the mmap'd file:
pe = pefile.PE(SrcPath, fast_load = True)
# Then just close the internal mmap view of the file.
pe.__data__.close()
Original comment by ero.carr...@gmail.com
on 19 May 2014 at 9:27
[deleted comment]
Hi,
I have the same issue.
Only "workaround" that is working for me is to use an own open,read,close
function:
with open(file, "rb") as file_content:
pe= pefile.PE(data=file_content.read(), fast_load=True)
Suggested solutions like:
del pe
or
pe.__data__.close()
did not work
Using Python 3.4.2
Original comment by CatWisel...@gmail.com
on 13 Nov 2014 at 1:49
Original issue reported on code.google.com by
SpindolaFilipe@gmail.com
on 15 May 2014 at 1:22