unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#13610: 24.3.50; vc-next-action hang forever
@ 2013-02-02 18:03 Thierry Volpiatto
  2013-02-02 18:35 ` Thierry Volpiatto
  0 siblings, 1 reply; 4+ messages in thread
From: Thierry Volpiatto @ 2013-02-02 18:03 UTC (permalink / raw)
  To: 13610


Hi,
To reproduce:
emacs -Q
create a new file and edit it (a script shell for me)
save it and register it under RCS.
C-x v v
emacs hang forever.

In GNU Emacs 24.3.50.1 (x86_64-unknown-linux-gnu, X toolkit)
 of 2013-01-31 on dell-14z
Windowing system distributor `The X.Org Foundation', version 11.0.11103000
System Description:	Ubuntu 12.04.2 LTS

Configured using:
 `configure --with-x-toolkit=lucid --without-toolkit-scroll-bars'

Important settings:
  value of $LANG: fr_FR.UTF-8
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Shell-script


-- 
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#13610: 24.3.50; vc-next-action hang forever
  2013-02-02 18:03 bug#13610: 24.3.50; vc-next-action hang forever Thierry Volpiatto
@ 2013-02-02 18:35 ` Thierry Volpiatto
  2013-02-04  7:07   ` Thierry Volpiatto
  0 siblings, 1 reply; 4+ messages in thread
From: Thierry Volpiatto @ 2013-02-02 18:35 UTC (permalink / raw)
  To: 13610

Thierry Volpiatto <thierry.volpiatto@gmail.com> writes:

> Hi,
> To reproduce:
> emacs -Q
> create a new file and edit it (a script shell for me)
> save it and register it under RCS.
> C-x v v
> emacs hang forever.

More exactly, this is this loop (which is not in 24.2.92) which 
turn forever because it assume buffer have been modified before setq'ing
files to nil and stop the loop.

--8<---------------cut here---------------start------------->8---
    ;; If a buffer has unsaved changes, a checkout would discard those
    ;; changes, so treat the buffer as having unlocked changes.
    (when (and (not (eq model 'implicit)) (eq state 'up-to-date))
      (let ((files files))
	(while files
	  (let ((buffer (get-file-buffer (car files))))
	    (and buffer
		 (buffer-modified-p buffer)
		 (setq state 'unlocked-changes
		       files nil))))))
--8<---------------cut here---------------end--------------->8---


-- 
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 






^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#13610: 24.3.50; vc-next-action hang forever
  2013-02-02 18:35 ` Thierry Volpiatto
@ 2013-02-04  7:07   ` Thierry Volpiatto
  2013-02-04 21:24     ` Stefan Monnier
  0 siblings, 1 reply; 4+ messages in thread
From: Thierry Volpiatto @ 2013-02-04  7:07 UTC (permalink / raw)
  To: 13610

Thierry Volpiatto <thierry.volpiatto@gmail.com> writes:

> Thierry Volpiatto <thierry.volpiatto@gmail.com> writes:
>
>> Hi,
>> To reproduce:
>> emacs -Q
>> create a new file and edit it (a script shell for me)
>> save it and register it under RCS.
>> C-x v v
>> emacs hang forever.
>
> More exactly, this is this loop (which is not in 24.2.92) which 
> turn forever because it assume buffer have been modified before setq'ing
> files to nil and stop the loop.
>
>     ;; If a buffer has unsaved changes, a checkout would discard those
>     ;; changes, so treat the buffer as having unlocked changes.
>     (when (and (not (eq model 'implicit)) (eq state 'up-to-date))
>       (let ((files files))
> 	(while files
> 	  (let ((buffer (get-file-buffer (car files))))
> 	    (and buffer
> 		 (buffer-modified-p buffer)
> 		 (setq state 'unlocked-changes
> 		       files nil))))))

--8<---------------cut here---------------start------------->8---
diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
index 9b8b949..18147cd 100644
--- a/lisp/vc/vc.el
+++ b/lisp/vc/vc.el
@@ -1084,8 +1084,8 @@ For old-style locking-based version control systems, like RCS:
 	  (let ((buffer (get-file-buffer (car files))))
 	    (and buffer
 		 (buffer-modified-p buffer)
-		 (setq state 'unlocked-changes
-		       files nil))))))
+		 (setq state 'unlocked-changes)))
+          (setq files (cdr files)))))
 
     ;; Do the right thing
     (cond
--8<---------------cut here---------------end--------------->8---

-- 
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 






^ permalink raw reply related	[flat|nested] 4+ messages in thread

* bug#13610: 24.3.50; vc-next-action hang forever
  2013-02-04  7:07   ` Thierry Volpiatto
@ 2013-02-04 21:24     ` Stefan Monnier
  0 siblings, 0 replies; 4+ messages in thread
From: Stefan Monnier @ 2013-02-04 21:24 UTC (permalink / raw)
  To: Thierry Volpiatto; +Cc: 13610-done

> -		 (setq state 'unlocked-changes
> -		       files nil))))))
> +		 (setq state 'unlocked-changes)))
> +          (setq files (cdr files)))))

Thanks.
I installed a further patch that uses dolist instead, so there's no risk
of forgetting the setq+cdr.


        Stefan





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-02-04 21:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-02 18:03 bug#13610: 24.3.50; vc-next-action hang forever Thierry Volpiatto
2013-02-02 18:35 ` Thierry Volpiatto
2013-02-04  7:07   ` Thierry Volpiatto
2013-02-04 21:24     ` Stefan Monnier

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.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).