Menu

#329 The call to FreeImage_OpenMultiBitmap crashes the calling Windows process if filename is longer than 255 characters and Windows Long Path is disabled.

open
nobody
None
5
2021-06-09
2021-02-28
No

The call to FreeImage_OpenMultiBitmap crashes the calling Windows process if filename is longer than 255 characters and Windows Long Path is disabled.
- the call never returns any value, even NULL.
- the calling Windows process silently crashes
- and even Natural Exception is not created.

The expected behavior: if file name violates Windows restrictions, the call to function FreeImage_OpenMultiBitmap would return NULL value instead of crashing the calling process

The attached example reproduces the issue.

1 Attachments

Discussion

  • Mihail Naydenov

    Mihail Naydenov - 2021-03-01

    Here is a patch.

     
  • Daniel Zinchin

    Daniel Zinchin - 2021-06-08

    Thanks, Mikhail!
    Will this fix the part of upcoming official release?

     
  • Mihail Naydenov

    Mihail Naydenov - 2021-06-08

    I don't know, it is up to @drolon, I am not a maintainer. That being said, I have GitHub clone of FreeImage that probably includes this patch (can't remember honestly). https://github.com/mnaydenov/FreeImage-Adv
    If you are not afraid to compile from code, you can give it a try. (Read about the branches, because it is quite busy there!)

     
  • Daniel Zinchin

    Daniel Zinchin - 2021-06-09

    Thanks, Mihail. But my bosses want to take a fix with official release. I'll ask @drolon

     

Log in to post a comment.