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

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

SCCS version control cannot cope when latest delta is of type 'removed'


From: Chet Wood
Subject: SCCS version control cannot cope when latest delta is of type 'removed'
Date: Thu, 26 Oct 2006 17:32:08 -0700 (PDT)

This bug report will be sent to the Free Software Foundation,
not to your local site managers!
Please write in English, because the Emacs maintainers do not have
translators to read other languages for them.

Your bug report will be posted to the address@hidden mailing list,
and to the gnu.emacs.bug news group.

In GNU Emacs 21.4.1 (sparc-sun-solaris2.8, X toolkit)
 of 2005-12-14 on pkg-build
configured using `configure  --prefix=/pkg/gnu 
--x-includes=/usr/openwin/include:/usr/dt/include 
--x-libraries=/usr/openwin/lib:/usr/dt/lib --with-x --with-x-toolkit=athena 
--without-toolkit-scroll-bars --with-xpm --with-tiff --with-jpeg --with-gif 
--with-png'
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: nil
  locale-coding-system: nil
  default-enable-multibyte-characters: t

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

In the shell using regular sccs commands, or in emacs using C-x C-q,
check out an sccs-versioned file that has had its latest delta
removed. Then, in another emacs session, VC commands, such as
vc-directory or vc-next-action, fail.

When vc-sccs-workfile-version(file) searches for the latest version
number in the sccs file, it searches for "^Ad D". However, there can
be another type of delta, namely "^Ad R". In this case, the delta does
not really exist-- it was removed, leaving this delta entry as a
"bread crumb" in the sccs file. The search is limited to the first
delta entry, so it fails and the function returns nil, and as a
result, a blank version number is passed to vcdiff and it fails.

I tried changing the search to accept [D|R] but it then returns the
removed delta number, which does not really exist, and other errors
ensue. 

(This scenario happens sometimes when the Sun CodeManager configuration
management tool is used. It apparently inserts its own bookkeeping
comments by adding and removing a delta. It seems to happen when a new
file is added to the workspace, then the workspace is putback to
another workspace.)

Suggested Fix:
The search should skip the top delta in the sccs file if it is of type
"removed", and return the version number of the next delta.
But IMHO it would be more robust to run the command "sccs
prt filename" to obtain the version, rather than relying on the
internal file format, assuming this works on all platforms.

A workaround is to make a change to the checked-out file (like adding
a blank line to the end or any other change) and check it back
in outside of emacs, creating a real latest delta. Then it can be
checked out again, and should work fine.

Thanks.

Chet Wood
Sun Microsystems


Recent input:
C-x C-b C-x o C-n C-n o C-p C-p C-p C-p C-p C-SPC C-n 
C-n C-n C-n C-n <escape> w C-p C-p C-p C-p C-p C-p 
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-n C-SPC C-n 
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n 
C-n C-x C-x C-x C-x C-x C-x C-x C-x <escape> w M-x 
e m a c s - r e p SPC <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> r e p o r SPC b SPC u SPC <backspace> <backspace> 
<backspace> SPC SPC SPC <return>

Recent messages:
vc-sccs-workfile-version
Reading directory /home/cwood/tmp/p/...done
Buffer includes 3 directories
Getting version information... 
Running vcdiff on /home/cwood/tmp/p/SCCS/s.x_10.h...
vc-do-command: Running vcdiff...FAILED (status 2)
Reading directory /home/cwood/tmp/p/...done
Mark set [2 times]
Saved text from ";; Codemgr inserts and deletes a delta i"
Loading emacsbug...done




reply via email to

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