release: prepare v2.0.53 updater handoff
Launch the verified NSIS installer directly before application shutdown, wait for Windows to confirm process creation, and keep the application open on spawn failure. Move process waiting into NSIS with a bounded graceful and post-force termination check, and cover the handoff with updater regression tests.
This commit is contained in:
+15
-3
@@ -9,11 +9,23 @@
|
||||
Goto update_ready
|
||||
${endif}
|
||||
IntOp $R1 $R1 + 1
|
||||
${if} $R1 >= 40
|
||||
${if} $R1 >= 300
|
||||
nsExec::Exec `"$SYSDIR\cmd.exe" /c taskkill /f /im "${APP_EXECUTABLE_FILENAME}" /fi "USERNAME eq %USERNAME%"`
|
||||
Pop $R0
|
||||
Sleep 500
|
||||
Goto update_ready
|
||||
StrCpy $R2 0
|
||||
update_force_wait:
|
||||
!insertmacro FIND_PROCESS "${APP_EXECUTABLE_FILENAME}" $R0
|
||||
${if} $R0 != 0
|
||||
Goto update_force_ready
|
||||
${endif}
|
||||
IntOp $R2 $R2 + 1
|
||||
${if} $R2 >= 150
|
||||
Quit
|
||||
${endif}
|
||||
Sleep 200
|
||||
Goto update_force_wait
|
||||
update_force_ready:
|
||||
Goto update_ready
|
||||
${endif}
|
||||
Sleep 200
|
||||
Goto update_wait
|
||||
|
||||
Reference in New Issue
Block a user