gabr42/OmniThreadLibrary

Bug in DSiWin32.DSiUnregisterUserFileAssoc

PeterPanino opened this issue · 1 comments

There is a bug in DSiWin32.DSiUnregisterUserFileAssoc that does not work (Delphi 10.4.2 in Windows 10):

procedure DSiUnregisterUserFileAssoc(const progID: string);
begin
  DSiKillRegistry('\Software\Classes\' + progID, HKEY_CURRENT_USER);
end;

This is the correct code:

procedure DSiUnregisterUserFileAssoc(const progID: string);
begin
  DSiKillRegistry('\Software\Classes\' + progID, HKEY_CURRENT_USER, KEY_ALL_ACCESS);
end;

@AndreasRejbrand has discovered the bug here: https://stackoverflow.com/questions/67519443/how-to-unregister-a-file-format-for-my-application

Fixed, thanks for pointing it out.