From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Mark Oteiza Newsgroups: gmane.emacs.devel Subject: [PATCH 2/3] lisp/mpc.el (mpc-file-local-copy): check for absolute path Date: Mon, 7 Sep 2015 19:31:21 -0400 Message-ID: <1441668682-21988-2-git-send-email-mvoteiza@udel.edu> References: <1441668682-21988-1-git-send-email-mvoteiza@udel.edu> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1441668730 19153 80.91.229.3 (7 Sep 2015 23:32:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 7 Sep 2015 23:32:10 +0000 (UTC) Cc: Mark Oteiza To: Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 08 01:31:56 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZZ5tA-0000BV-7y for ged-emacs-devel@m.gmane.org; Tue, 08 Sep 2015 01:31:52 +0200 Original-Received: from localhost ([::1]:59246 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZ5t9-0007SG-Gd for ged-emacs-devel@m.gmane.org; Mon, 07 Sep 2015 19:31:51 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33123) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZ5t1-0007OB-Pm for emacs-devel@gnu.org; Mon, 07 Sep 2015 19:31:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZZ5sy-00052M-KW for emacs-devel@gnu.org; Mon, 07 Sep 2015 19:31:43 -0400 Original-Received: from mail-qg0-f42.google.com ([209.85.192.42]:34819) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZ5sy-00052H-Hx for emacs-devel@gnu.org; Mon, 07 Sep 2015 19:31:40 -0400 Original-Received: by qgt47 with SMTP id 47so70362879qgt.2 for ; Mon, 07 Sep 2015 16:31:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=GrUd0bw7tmzh+LFI7D3R6cfYqXGARfnJcRlJ4W6ENuw=; b=Z+JxQrUPuIJMJtdPe4cC09pA24HLSZvdl7EkBNI09KbWTxvnwZwpiymJ6j4yWOasW0 14KJ7NLBh3pFBLO57txpYrR9tTDdKoieMbeQWiCr4ThKBaVoap0oRHXsGXQfHOjJLJOw qwvucbGGbfbLjRcQo/8DusDSIThbwALIkKpALE2lbKvr9RQbW6QKsGhXRgdKQfZ8VWRp c9ru8kwbb2Exid6KIprFVO0O4o0HDS5C/PnpRSRqlgL88l1WO/C1iDSOk4nctV/6C7jS mySsoiSi4OXaHR3O0UFfapIGH7s73xL4WFtn9na8LyUWHvWSnmpvXoiG2DwEzdelIABK Zt1Q== X-Gm-Message-State: ALoCoQmdXqGJePn6C4GCa65GOjUnuNL6p4PDXmbygseKtgAOxLGijxf12Ikxa1qLfLGv5It2awbB X-Received: by 10.140.133.67 with SMTP id 64mr32145914qhf.52.1441668700293; Mon, 07 Sep 2015 16:31:40 -0700 (PDT) Original-Received: from holos.localdomain (c-73-172-248-173.hsd1.md.comcast.net. [73.172.248.173]) by smtp.gmail.com with ESMTPSA id f86sm764775qkf.0.2015.09.07.16.31.39 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Sep 2015 16:31:39 -0700 (PDT) Original-Received: by holos.localdomain (Postfix, from userid 1000) id D065568971; Mon, 7 Sep 2015 19:31:39 -0400 (EDT) X-Mailer: git-send-email 2.5.1 In-Reply-To: <1441668682-21988-1-git-send-email-mvoteiza@udel.edu> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.192.42 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:189687 Archived-At: --- lisp/mpc.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/mpc.el b/lisp/mpc.el index 740b865..643aa0e 100644 --- a/lisp/mpc.el +++ b/lisp/mpc.el @@ -909,7 +909,8 @@ If PLAYLIST is t or nil or missing, use the main playlist." (defun mpc-file-local-copy (file) ;; Try to set mpc-mpd-music-directory. (when (and (null mpc-mpd-music-directory) - (string-match "\\`localhost" mpc-host)) + (or (string-match "\\`localhost" mpc-host) + (file-name-absolute-p mpc-host))) (let ((files `(,(let ((xdg (getenv "XDG_CONFIG_HOME"))) (concat (if (and xdg (file-name-absolute-p xdg)) xdg "~/.config") -- 2.5.1