emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Todd Neal <tolchz@tolchz.net>
To: emacs-orgmode@gnu.org
Subject: Lockup in org-get-tags-at (4.32)
Date: Wed, 24 May 2006 00:29:40 -0400	[thread overview]
Message-ID: <87wtccjb9n.fsf@tolchz.net> (raw)



I was trying to archive a TODO item and org-mode locked up.  I've
traced it down to org-get-tags-at which never returns. Below is a
stack trace with the "looping" portion marked.

--- End Loop
  org-outline-level()
  outline-up-heading(1 t)
  org-up-heading-all(1)
--- Loop
  org-get-tags-at()
  org-set-tags(nil t)
  org-promote()
  org-map-region(org-promote 1426 1480)
  org-paste-subtree(1)
  org-archive-subtree()


Hopefully, these lines won't get wrapped:

     1	(defun org-get-tags-at (&optional pos)
     2	  "Get a list of all headline tags applicable at POS.
     3	POS defaults to point.  If tags are inherited, the list contains
     4	the targets in the same sequence as the headlines appear, i.e.
     5	the tags of the current headline come last."
     6	  (interactive)
     7	  (let (tags)
     8	    (save-excursion
     9	      (goto-char (or pos (point)))
    10	      (save-match-data
    11		(org-back-to-heading t)
    12		(condition-case nil
    13		    (while t
    14		      (if (looking-at "[^\r\n]+?:\\([a-zA-Z_@0-9:]+\\):[ \t]*\\([\n\r]\\|\\'\\)")
    15			  (setq tags (append (org-split-string 
    16					      (org-match-string-no-properties 1) ":")
    17					     tags)))
    18		      (or org-use-tag-inheritance (error ""))
    19		      (org-up-heading-all 1))
    20		  (error nil))))
    21	    (message "%s" tags)
    22	    tags))


It is clearly stuck in the while loop between lines 13-19 but I'm not
sure why.  Does anyone else experience this behavior?

Todd

             reply	other threads:[~2006-05-24  4:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-24  4:29 Todd Neal [this message]
2006-05-24  7:02 ` Lockup in org-get-tags-at (4.32) Carsten Dominik
2006-05-24 22:38   ` Todd Neal

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=87wtccjb9n.fsf@tolchz.net \
    --to=tolchz@tolchz.net \
    --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).