'Close the file. Will handle quarantining file if necessary.'

def close(self):

    if self._fp:
        try:
            if (self._started_at_0 and self._read_to_eof):
                self._handle_close_quarantine()
        except (Exception, Timeout):
            pass
        finally:
            self._fp = None
