Skip to content

Corrupt MSG cannot close after error.  #417

@ragebear00

Description

@ragebear00

Bug Metadata

  • Version of extract_msg: 0.48.5
  • Your python version: Python [3.10]
  • How did you launch extract_msg?
    I used the extract_msg package

Describe the bug
If the “msg” is corrupt and extract_msg.openMsg(filename) will fail, BUT file will not close() after the error. Python will keep the file open until the process is closed.

Additional context
Just add “self.close(“) in \extract_msg\msg_classes\msg.py before “raise StandardViolationError('File does not contain a property stream.') from None” can solve the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions