quartz: Open files with FILE_SHARE_DELETE in FileSource.
commit9cfd5d00ca5a0643e15279d7ea7ca7db5be698a4
authorDavid Gow <david@ingeniumdigital.com>
Sun, 31 Jul 2022 01:58:09 +0000 (31 09:58 +0800)
committerAlexandre Julliard <julliard@winehq.org>
Wed, 10 Aug 2022 09:35:08 +0000 (10 11:35 +0200)
treee6d1d45a9b1a472d74cac3c4448f8db87fb93ddb
parentda581d383d411b877ea7ee5b96e307877a4d3181
quartz: Open files with FILE_SHARE_DELETE in FileSource.

Some games (such as Digimon Survive) create temporary video files and
will hang if deleting them fails. Open the files with FILE_SHARE_DELETE,
which will allow this deletion to go ahead even if the FileSource hasn't
yet been closed.

Note that many windows codec packs do themselves open files without
FILE_SHARE_DELETE, so a similar hang can be observed in some windows
configurations.

I haven't checked that this is the file share mode used on windows
(alas, I don't have a windows machine available), so I haven't removed
the FIXME comment. Equally, I also updated the CreateFileW() call
in get_media_type(), but that _may_ be unnecessary.

Signed-off-by: David Gow <david@ingeniumdigital.com>
dlls/quartz/filesource.c