в ~/.emacs в конце есть следующее
(global-set-key (kbd "M-s") 'other-window)
То есть переключение на следующее окно.
В некоторых режимах не работает, M-x describe-key говорит следующее:
M-s runs the command comint-next-matching-input, which is an
interactive compiled Lisp function.
It is bound to M-s, <menu-bar> <inout> <next-matching-history>.
(comint-next-matching-input regexp n)
Search forwards through input history for match for regexp.
(Later history elements are more recent commands.)
With prefix argument n, search for nth following match.
If n is negative, find the previous or nth previous match.
Почему так происходит?