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

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

Re: C-c C-c in recover session produces "Args out of range"


From: Boris Aronov
Subject: Re: C-c C-c in recover session produces "Args out of range"
Date: Fri, 13 Jun 2003 18:59:03 -0400 (EDT)

Ooooooops...  [I just thought I removed the .saves-XXXX file.  I did
not, in fact.]  

So indeed the file, to be more precise that what I reported earlier
contains:

=========
/home/aronov/papers/separation/2003-06-05/separability.tex
/home/aronov/papers/separation/2003-06-05/#separability.tex#






=========

(Note the oodles of extra empty lines at the end---I checked that they
really ARE empty.)  On advice of RMS, I re-run the stack trace with
uncompiled function "recover-session-finish" and got:

=========
Debugger entered--Lisp error: (args-out-of-range "" 1 -1)
  substring("" 1 -1)
  (expand-file-name (substring (file-name-nondirectory autofile) 1 -1) 
(file-name-directory autofile))
  (setq thisfile (expand-file-name (substring ... 1 -1) (file-name-directory 
autofile)))
  (progn (forward-line 1) (setq autofile (buffer-substring-no-properties ... 
...)) (setq thisfile (expand-file-name ... ...)) (forward-line 1))
  (if (eolp) (progn (forward-line 1) (setq autofile ...) (setq thisfile ...) 
(forward-line 1)) (progn (setq thisfile ...) (forward-line 1) (setq autofile 
...) (forward-line 1)))
  (let (thisfile autofile) (if (eolp) (progn ... ... ... ...) (progn ... ... 
... ...)) (if (file-exists-p autofile) (setq files ...)))
  (while (not (eobp)) (let (thisfile autofile) (if ... ... ...) (if ... ...)))
  (save-excursion (set-buffer buffer) (erase-buffer) (insert-file-contents 
file) (while (not ...) (let ... ... ...)) (setq files (nreverse files)) (if 
files (map-y-or-n-p "Recover %s? " ... files ...) (message "No files can be 
recovered from this session now")))
  (unwind-protect (save-excursion (set-buffer buffer) (erase-buffer) 
(insert-file-contents file) (while ... ...) (setq files ...) (if files ... 
...)) (kill-buffer buffer))
  (let ((file ...) files (buffer ...)) (dired-unmark 1) 
(dired-do-flagged-delete t) (unwind-protect (save-excursion ... ... ... ... ... 
...) (kill-buffer buffer)))
  recover-session-finish()
  call-interactively(recover-session-finish)
=============

I patched the file as you suggested and the error went away.  Since
there are no recoverable things in that .saves-XXX file, I cannot say
much beyond that about its functionality.  I will try to test it the
next time I have to use recover-session.  Thanks!

     --Boris




reply via email to

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