emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Stephan Schmitt <drmabuse@cs.tu-berlin.de>
To: emacs-orgmode@gnu.org
Subject: Bug when following a link (org-open-at-point)
Date: Wed, 27 Sep 2006 11:41:48 +0200	[thread overview]
Message-ID: <451A475C.6080504@cs.tu-berlin.de> (raw)

hello,

i just downloaded org-mode 4.50 and
got an error when i tried to follow
an internal link (C-c C-o, Mouse-2).

i traced the problem back to following
function in org.el:

(defun org-file-remote-p (file)
  "Test whether FILE specifies a location on a remote system.
Return non-nil if the location is indeed remote.

For example, the filename \"/user@host:/foo\" specifies a location
on the system \"/user@host:\"."
  (cond ((fboundp 'file-remote-p)
         (file-remote-p file))
        ((fboundp 'tramp-handle-file-remote-p)
         (tramp-handle-file-remote-p file))
        ((and (boundp 'ange-ftp-name-format)
              (string-match ange-ftp-name-format file))
         t)
        (t nil)))

the third condition (string-match ange-ftp-name-format file)
tries to match a list against a string,
ange-ftp.el:

(defcustom ange-ftp-name-format
  '("^/\\(\\([^@/:]*\\)@\\)?\\([^@/:]*[^@/:.]\\):\\(.*\\)" . (3 2 4))
  "*Format of a fully expanded remote file name.

This is a list of the form \(REGEXP HOST USER NAME\),
where REGEXP is a regular expression matching
the full remote name, and HOST, USER, and NAME are the numbers of
parenthesized expressions in REGEXP for the components (in that order)."
  :group 'ange-ftp
  :type '(list regexp
	       (integer :tag "Host group")
	       (integer :tag "User group")
	       (integer :tag "Name group")))

i solved the problem by changing the condition
(string-match ange-ftp-name-format file)
into
(string-match (car ange-ftp-name-format) file)

best regards,
	stephan

             reply	other threads:[~2006-09-27  8:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-27  9:41 Stephan Schmitt [this message]
2006-09-27 21:52 ` Bug when following a link (org-open-at-point) Carsten Dominik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=451A475C.6080504@cs.tu-berlin.de \
    --to=drmabuse@cs.tu-berlin.de \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).