@cfry Dirty 1 is pd's internal message saying the canvas has been altered so if you send that message when the patch is loaded pd will think the canvas has been changed even if it hasn't. It will not prevent you from just hitting enter and saving the patch allowing pd to quit and freeze but it might be enough to remind you that you need to kill tee before quiting. First version only works with recent versions of pd, not sure how new it has to be since it is another one of those features they forgot to mention and never put in the change log, I think it needs 54 but I don't really know, second version works quite a ways back.

You can also try [iemguts/closebang], stick it in the abstraction and have it trigger the killall tee but that may not work and we may have already explored that, don't remember.