bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#10071: 24.0.91; Emacs runtime crashes while exporting an org file


From: Jambunathan K
Subject: bug#10071: 24.0.91; Emacs runtime crashes while exporting an org file
Date: Fri, 18 Nov 2011 22:29:16 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.91 (windows-nt)

Eli, Thanks for the clue and Stefan, thanks for the fix meanwhile. The
minimal snippet that captures the root cause follows down below.

Nicolas Goaziou <address@hidden> writes:
> Hello,
>
> Jambunathan K <address@hidden> writes:
>
>> Ccing Nicolas to attract his attention.
>>
>> Refer http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10071 
>
> I cannot reproduce it on development version of Org mode (nor in stable
> version), GNU Emacs 24.0.91.1 (x86_64-unknown-linux-gnu, GTK+ Version
> 3.2.1).
>
> Jambunathan, can you debug `org-export-normalize-links' before Emacs
> crashes?



#+begin_src emacs-lisp
;; install blah in the run-time
(defun blah () 
  (goto-char (point-min))
  (while (re-search-forward
          "\\[\\[\\([^][]+\\)\\]\\(\\[\\([^][]+\\)\\]\\)?\\]" nil t)
    (goto-char (1- (match-end 0)))
    (org-if-unprotected
     (let* ((xx (match-string 1))
            (s (concat "[[" xx "][" xx "]]")))
       (replace-match s t t)))))
#+end_src


;; eval the 3 forms in sequence. Note that the third form will crash
;; emacs

#+begin_src emacs-lisp
;; form 1
;; here link < buffer
;; link *is* decorated
(with-temp-buffer
  ;; (insert "[[http://www.google.com]]";)
  (insert "[[http://www.google.com]]a";) ; Note the extra "a" at the
                                        ; end
  (add-text-properties (point-min) (point-max)
                       '(org-caption nil org-caption-shortn nil
                                     org-label nil org-attributes nil))
  (blah))
#+end_src


#+begin_src emacs-lisp
;; form 2
;; here link = buffer
;; link is *not* decorated
(with-temp-buffer
  (insert "[[http://www.google.com]]";)
  ;; (insert "[[http://www.google.com]]a";)
  
  ;; (add-text-properties (point-min) (point-max)
  ;;                   '(org-caption nil org-caption-shortn nil
  ;;                                 org-label nil org-attributes nil))

  (blah))
#+end_src


#+begin_src emacs-lisp
;; form 3
;; here link = buffer
;; link *is* decorated
(with-temp-buffer
  (insert "[[http://www.google.com]]";)
  ;; (insert "[[http://www.google.com]]a";)
  (add-text-properties (point-min) (point-max)
                       '(org-caption nil org-caption-shortn nil
                                     org-label nil org-attributes nil))
  (blah))
#+end_src



> Regards,





reply via email to

[Prev in Thread] Current Thread [Next in Thread]