Fix xref-find-references on MS-Windows

* lisp/cedet/semantic/symref/grep.el
(semantic-symref-derive-find-filepatterns): Use
'shell-quote-argument' instead of manually quoting in a way that
only works with Posix shells.  (Bug#22289)
This commit is contained in:
Eli Zaretskii 2016-01-02 17:24:48 +02:00
parent 55a28d8a1b
commit fe903ef7cf

View file

@ -75,14 +75,14 @@ Optional argument MODE specifies the `major-mode' to test."
)))
;; Convert the list into some find-flags.
(cond ((= (length pat) 1)
(concat "-name \"" (car pat) "\""))
(concat "-name " (shell-quote-argument (car pat))))
((consp pat)
(concat "\\( "
(concat (shell-quote-argument "(") " "
(mapconcat (lambda (s)
(concat "-name \"" s "\""))
(concat "-name " (shell-quote-argument s)))
pat
" -o ")
" \\)"))
" " (shell-quote-argument ")")))
(t
(error "Customize `semantic-symref-filepattern-alist' for %s" major-mode))
)))