It'd be very useful to try to detect it and at least stop the second instance from loading and using the desktop file if it's already in use. There's no way to do that from Emacs, is there?
It needs to use file-locking together with testing of the file modtime. There are primitives to do this: lock-file and unlock-file, and file-attributes. So when you restore an old desktop, you record the modtime of the file. When you update the desktop file, you lock it, them see if its modtime is the same as it was when you restored the desktop. If not, you do whatever. _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel