Description: LO provides the SimpleMail interface to compose and send mails on Windows using a wrapped MAPI. When using SimpleMail with multiple attachments, this crashes Outlook 2016 or returns an MAPI_E_FAILURE. This is a regression from commit 5874c7637156 ("tdf#116074: Use modeless dialogs with supporting mailers"). There seems to be multiple problems with the usage of MAPI_DIALOG_MODELESS. Even IE uses MAPI_DIALOG and threads, to prevent the blocking. Steps to Reproduce: 1. Execute the attached email macro or 1. run senddoc.exe with a variant of --subject Test --to SMTP:a@b.cd --attach C:\Users\JAN-MA~1\AppData\Local\Temp\lu2996h1g7x4.tmp --attach-name a.pdf --attach C:\Users\JAN-MA~1\AppData\Local\Temp\lu2996h1g7x5.tmp --attach-name b.pdf --mapi-dialog --mapi-logon-ui --langtag de-DE --bootstrap file:///C:/LODEV/program/soffice.ini For the macro variant senddoc.exe is run in the background for current LO master. Actual Results: Outlook 2016 crashes (most times) or reports an MAPI_E_FAILURE. Expected Results: No crash Reproducible: Always User Profile Reset: No Additional Info: Just happens with software that actually supports MAPI_DIALOG_MODELESS.
Created attachment 153032 [details] Crash macro
Created attachment 153033 [details] Dummy attachment a.pdf
Created attachment 153034 [details] Dummy attachment b.pdf
> Outlook 2016 crashes (most times) or reports an MAPI_E_FAILURE. confirming, reproducible in our windows 7 environment
Jan-Marek Glogowski committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/+/e79f61340405dcc75f3fe41f727dea4ba4202c2e%5E%21 tdf#126597 don't use modeless dialog for senddoc.exe It will be available in 6.4.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Jan-Marek Glogowski committed a patch related to this issue. It has been pushed to "libreoffice-6-2": https://git.libreoffice.org/core/+/222e3782dfa885370c5adbaf87aeed4fcbb5f107%5E%21 tdf#126597 don't use modeless dialog for senddoc.exe It will be available in 6.2.7. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Jan-Marek Glogowski committed a patch related to this issue. It has been pushed to "libreoffice-6-3": https://git.libreoffice.org/core/+/b2c651b378b52f823b8350aece0fd1e6b914bdc5%5E%21 tdf#126597 don't use modeless dialog for senddoc.exe It will be available in 6.3.1. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.