This fixes a bug in EastMoney, which calls SetFileTypes() with a COMDLG_FILTERSPEC structure in which pszSpec = L"" followed by SetFileName(L"*.fml"). In windows, this matches all *.fml files. In wine, this matched no files. Before this patch, wine did not use filters from the file name field (marked as a FIXME) and a file type entry with an empty spec would match no files (as opposed to leaving the current filter unmodified).
The exact rules worked out by testing in a Windows 10 VM seem to be:
Current filter is initially empty and can be set by typing a filter
into the file name field (or SetFileName) or selecting an entry from the file type menu (or SetFileTypeIndex).
Selecting a file type entry with an empty spec leaves the current filter unchanged.
Selecting a file type entry with a non-empty spec clears the file name field if it currently contains a filter.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6443