With some regularity, I am using bash with M-x shell, and out of muscle memory I hit C-c C-c, with dramatic results:
- the
comintprompt streams a long error message with a large number of escaped characters; - several files are created in the working directory with only escaped characters in the name.
Is there any way to send a kill signal to the prompt from within comint-mode, similar to what is triggered in a normal bash terminal with C-c C-c?
Edit: this is in Emacs for OS X Modified, and it only happens sometimes when I press C-c C-c in shell-mode
C-c C-cin shell-mode sendscomint-interrupt-subjob, which does the same thing asC-cin a standard shell. I can confirm this on vanilla Emacs (started viaemacs -Q), none of the behaviours you describe occur. I suspect it may be due to the particular program you are trying to interrupt doing something strange. First thing to check: start emacs withemacs -Qand see if you can reproduce the problem. If you can't, the problem is in your init file.