Commits

Philippe Lagadec  committed 0a5bd04

Fixed issue 2 - added close method to OleFileIO class

  • Participants
  • Parent commits c4ea7e6

Comments (0)

Files changed (1)

File OleFileIO_PL/OleFileIO_PL.py

 # 2010-01-22 v0.21 PL: - added support for big-endian CPUs such as PowerPC Macs
 # 2012-02-16 v0.22 PL: - fixed bug in getproperties, patch by chuckleberryfinn
 #                        (https://bitbucket.org/decalage/olefileio_pl/issue/7)
+#                      - added close method to OleFileIO (fixed issue #2)
 
 #-----------------------------------------------------------------------------
 # TODO (for version 1.0):
         self.minifatsect = self.MiniFatStart #i32(header, 60)
 
 
+    def close(self):
+        """
+        close the OLE file, to release the file object
+        """
+        self.fp.close()
+
+
     def _check_duplicate_stream(self, first_sect, minifat=False):
         """
         Checks if a stream has not been already referenced elsewhere.