Cancelclose not firing

In debug, if I have document windows open that need saving,
App / Quit causes the cancelclose to fire on the windows and I am prompted to save

In the compiled app, same scenario, the cancelclose does not fire, and amended work is lost

Anyone else seen that?
Xojo 2018R3

How did you confirm the CancelClose event did not fire ?

Messageboxes.

I think I have found the issue.

https://forum.xojo.com/47967-using-terminate-declare-prevents-app-profiling-completion/0#p389212

I added a terminate call which only happens in non-debug builds.
Guess I need to see if this remains an issue without the terminate code.

Yup.
But having taken it out, seems like its not needed now.
Wonder how many little workarounds I still have in there from days gone by…