diff options
| author | Mark Oteiza | 2015-09-07 18:01:00 -0400 |
|---|---|---|
| committer | Mark Oteiza | 2015-09-10 13:41:09 -0400 |
| commit | 76093858d236b2134dd5db214d22a2b208c2992c (patch) | |
| tree | ecd83bf12dfd33def5439ac96fda9dcc308be831 | |
| parent | 2cf2b19985c4b3989a6ab9acfb247e2dc823669d (diff) | |
| download | emacs-76093858d236b2134dd5db214d22a2b208c2992c.tar.gz emacs-76093858d236b2134dd5db214d22a2b208c2992c.zip | |
lisp/mpc.el (mpc--proc-connect): use file-name-absolute-p
| -rw-r--r-- | lisp/mpc.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/mpc.el b/lisp/mpc.el index 3600b081f9b..bc7d4733ee8 100644 --- a/lisp/mpc.el +++ b/lisp/mpc.el | |||
| @@ -268,7 +268,10 @@ defaults to 6600 and HOST defaults to localhost." | |||
| 268 | (if (string-match "[^[:digit:]]" v) | 268 | (if (string-match "[^[:digit:]]" v) |
| 269 | (string-to-number v) | 269 | (string-to-number v) |
| 270 | v))))) | 270 | v))))) |
| 271 | (when (string-prefix-p "/" host) ;FIXME: Use file-name-absolute-p? | 271 | (when (file-name-absolute-p host) |
| 272 | ;; Expand file name because `file-name-absolute-p' | ||
| 273 | ;; considers paths beginning with "~" as absolute | ||
| 274 | (setq host (expand-file-name host)) | ||
| 272 | (setq local t)) | 275 | (setq local t)) |
| 273 | 276 | ||
| 274 | (mpc--debug "Connecting to %s:%s..." host port) | 277 | (mpc--debug "Connecting to %s:%s..." host port) |