From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: Bug: org-insert-link issues error when list of links is empty [6.33trans (release_6.33f.34.gf806)] Date: Thu, 26 Nov 2009 07:14:59 +0100 Message-ID: <3F3E7D61-D0E7-4C36-B9F9-44F18D51A283@gmail.com> References: <200911251813.nAPIDNn3001193@gollum.intra.norang.ca> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NDXdE-0005H0-Bw for emacs-orgmode@gnu.org; Thu, 26 Nov 2009 01:15:08 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NDXd9-0005FJ-Hc for emacs-orgmode@gnu.org; Thu, 26 Nov 2009 01:15:07 -0500 Received: from [199.232.76.173] (port=46758 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NDXd9-0005FA-63 for emacs-orgmode@gnu.org; Thu, 26 Nov 2009 01:15:03 -0500 Received: from mail-ew0-f224.google.com ([209.85.219.224]:63676) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NDXd8-0002ny-TH for emacs-orgmode@gnu.org; Thu, 26 Nov 2009 01:15:03 -0500 Received: by ewy24 with SMTP id 24so462062ewy.26 for ; Wed, 25 Nov 2009 22:15:02 -0800 (PST) In-Reply-To: <200911251813.nAPIDNn3001193@gollum.intra.norang.ca> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Bernt Hansen Cc: emacs-orgmode@gnu.org Fixed, thanks. - Carsten On Nov 25, 2009, at 7:13 PM, Bernt Hansen wrote: > > Remember to cover the basics, that is, what you expected to happen and > what in fact did happen. You don't know how to make a good report? > See > > http://orgmode.org/manual/Feedback.html#Feedback > > Your bug report will be posted to the Org-mode mailing list. > ------------------------------------------------------------------------ > > C-c C-l RET when there are no links in the list gives the following > backtrace. This should probably just report a more user-friendly > error message. > > -Bernt > > --8<---------------cut here---------------start------------->8--- > Debugger entered--Lisp error: (args-out-of-range "" -1 0) > substring("" -1) > (equal ":" (substring link -1)) > (and (equal ":" (substring link -1)) (member (substring link 0 -1) > all-prefixes) (setq link (substring link 0 -1))) > (or (member link all-prefixes) (and (equal ":" ...) (member ... all- > prefixes) (setq link ...))) > (if (or (member link all-prefixes) (and ... ... ...)) (setq link > (org-link-try-special-completion link))) > (progn (setq link (let ... ...)) (if (or ... ...) (setq link ...))) > (unwind-protect (progn (setq link ...) (if ... ...)) (set-window- > configuration wcf) (kill-buffer "*Org Links*")) > (cond (link-location) ((org-in-regexp org-bracket-link-regexp 1) > (setq remove ...) (setq desc ...) (setq link ...)) ((or ... ...) > (setq remove ... link ...)) ((member complete-file ...) (setq > link ...)) (t (with-output-to-temp-buffer "*Org Links*" ... ...) > (let ... ... ... ... ...) (setq tmphist ...) (setq all-prefixes ...) > (unwind-protect ... ... ...) (setq entry ...) (or entry ...) > (if ... ...) (setq desc ...))) > (let* ((wcf ...) (region ...) (remove ...) (desc region) tmphist > (link link-location) entry file all-prefixes) (cond (link-location) > (... ... ... ...) (... ...) (... ...) > (t ... ... ... ... ... ... ... ... ...)) (if (string-match org-plain- > link-re link) (setq link ...)) (when (and buffer-file-name ...) > (let* ... ...)) (when (string-match "^file:\\(.*\\)" link) > (let* ... ... ... ...)) (if org-make-link-description-function (setq > desc ...)) (setq desc (read-string "Description: " desc)) (unless > (string-match "\\S-" desc) (setq desc nil)) (if remove (apply ... > remove)) (insert (org-make-link-string link desc))) > org-insert-link(nil) > call-interactively(org-insert-link) > --8<---------------cut here---------------end--------------->8--- > > > Emacs : GNU Emacs 22.2.1 (i486-pc-linux-gnu, GTK+ Version 2.12.11) > of 2008-11-09 on raven, modified by Debian > Package: Org-mode version 6.33trans (release_6.33f.34.gf806) > > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten