Stefan Monnier writes: >> I guess "recursive-edit" is the only way to enter a recursive edit? > > AFAICT, `recursive_edit_1' is the C function that's used by both > `recursive-edit' and `read-from-minibuffer', so it should catch all cases. So, tried it, and AFAICT, you are correct. The attached patch seems to fix. And it is significantly simpler than the last fix. It currently does not deal with the case where there "left over" after a command which changes a recursive edit level. The lists of buffers in undo-auto-undoably-changed-buffer will be lost as we come out of the specbind. I do not know whether this is a problem or not. Potential solutions: 1) before we exit recursive_edit_1, append the value of undo-auto-undoably-changed-buffer on a new variable ("undoably-changed-buffer-recursive"). Then, when undo-auto-boundary runs append and nil this. Seems like a lot of effort for an occasional issue. 2) Call undo-auto--add-boundary before exiting recursive_edit_1. This should nil undoably-changed-buffer and add boundaries. 3) Just not worry about it. Assuming we go for 3, is everyone happy to patch the Emacs-25 branch? Phil