Bug 737833 - Add support for clearing out orphaned entries. r=rstrong

This commit is contained in:
Brian R. Bondy 2012-09-17 15:22:33 -04:00
Родитель 9edffdfab0
Коммит 8d0475bda7
1 изменённых файлов: 6 добавлений и 2 удалений

Просмотреть файл

@ -6969,9 +6969,11 @@
ReadRegStr $R8 HKCU "Software\Classes\CLSID\$R0\LocalServer32" "" ReadRegStr $R8 HKCU "Software\Classes\CLSID\$R0\LocalServer32" ""
${${un}GetLongPath} "$INSTDIR" $R7 ${${un}GetLongPath} "$INSTDIR" $R7
StrCmp "$R8" "" next +1 StrCmp "$R8" "" next +1
IfFileExists "$R8" +1 clearHKCU
${${un}GetParent} "$R8" $R8 ${${un}GetParent} "$R8" $R8
${${un}GetLongPath} "$R8" $R8 ${${un}GetLongPath} "$R8" $R8
StrCmp "$R7" "$R8" +1 next StrCmp "$R7" "$R8" clearHKCU next
clearHKCU:
DeleteRegKey HKCU "Software\Classes\CLSID\$R0" DeleteRegKey HKCU "Software\Classes\CLSID\$R0"
DeleteRegValue HKCU \ DeleteRegValue HKCU \
"Software\Classes\$AppUserModelID\.exe\shell\open\command" \ "Software\Classes\$AppUserModelID\.exe\shell\open\command" \
@ -6981,9 +6983,11 @@
ReadRegStr $R8 HKLM "Software\Classes\CLSID\$R0\LocalServer32" "" ReadRegStr $R8 HKLM "Software\Classes\CLSID\$R0\LocalServer32" ""
${${un}GetLongPath} "$INSTDIR" $R7 ${${un}GetLongPath} "$INSTDIR" $R7
StrCmp "$R8" "" done +1 StrCmp "$R8" "" done +1
IfFileExists "$R8" +1 clearHKLM
${${un}GetParent} "$R8" $R8 ${${un}GetParent} "$R8" $R8
${${un}GetLongPath} "$R8" $R8 ${${un}GetLongPath} "$R8" $R8
StrCmp "$R7" "$R8" +1 done StrCmp "$R7" "$R8" clearHKLM done
clearHKLM:
DeleteRegKey HKLM "Software\Classes\CLSID\$R0" DeleteRegKey HKLM "Software\Classes\CLSID\$R0"
DeleteRegValue HKLM \ DeleteRegValue HKLM \
"Software\Classes\$AppUserModelID\.exe\shell\open\command" \ "Software\Classes\$AppUserModelID\.exe\shell\open\command" \