Background: Exchange servers cannot accept "charset utf-8" search
strings. The code originally set that charset for any server with
literal+ capability, borking all searches on an Exchange server. This
code only sets utf-8 for multibyte search strings in particular, which
would be borken for Exchange anyway.
* lisp/gnus/gnus-search.el (gnus-search-imap-search-command): Ensure
we're only doing the literal+ dance for multibyte strings (multibyte
strings will have had newlines inserted in an earlier step).
Currently takes into account support for the LITERAL+ capability.
Other capabilities could be tested here."
(with-slots (literal-plus) engine
- (when literal-plus
+ (when (and literal-plus
+ (string-match-p "\n" query))
(setq query (split-string query "\n")))
(cond
((consp query)