delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/06/20/07:10:25

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,TW_YG
X-Spam-Check-By: sourceware.org
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-originating-ip:in-reply-to:references:from:date :message-id:subject:to:content-type:content-transfer-encoding :x-gm-message-state; bh=p9kg4knmJ8Kkbcum3VjO07qeZk/dO6pjSuvAv1luPGo=; b=BkG2wm1k1pHukeKHXOH3hX/Tts2XyqkHJGTUgh6lFk0fKnjsTCWHZ7s4skPVbpoqtN h+9SdHjFoiLtOMM3ORveaSeXSrTrdHRHoJlQhMo6X4D1hS4CUlAdSbWnwlqfSx0TFOBx n6nXPF6xrQmRuo3oTjeQIMNg82F1RKiPM130FVQWElk4HGuAoC8fTq6k77gsFWCblQSl o5rwXoeBNS+O9jtE79n5owFzzBKkccOwjoKhIve/AXnuR0OzmZyuSKLpMKBv8x+oaIBP 1FIfo2z9A2Xyu9vnIrdJUtCGGbNWUVye/EqhoBLNXu+ZnVKccyVC7y8lcwughTvUP1Gx T4lA==
MIME-Version: 1.0
In-Reply-To: <B7EEF3066CD1D24081DBFF5E9F5E68D4C17C1696@EXCNLDCM06.europe.unity>
References: <B7EEF3066CD1D24081DBFF5E9F5E68D4C17C1696 AT EXCNLDCM06 DOT europe DOT unity>
From: Richard Gribble <richard AT gandalfwizard DOT us>
Date: Wed, 20 Jun 2012 07:09:17 -0400
Message-ID: <CAD+0NRC-noW0-LxEjO_sCtP7SKdSWbaPoJU3zTwOs-pOMknkLg@mail.gmail.com>
Subject: Re: RCS file corruption.
To: cygwin AT cygwin DOT com
X-Gm-Message-State: ALoCoQlmQqE+Bjvhdmd5lIQ2sSeFwz/Zs2eI38vS+nj1629btK4T1oZnbTE5qAFAS72C8KaioAZG
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id q5KBAKAK032739

I have experienced this problem several times.  In my case it seemed
to be a problem between 'Unix' and 'DOS' files.  In each case, I have
been able to fix it by editing the RCS file using vim and deleting all
the extraneous carriage returns - :%s/^M$//<enter>  Sometimes I've had
to do it twice.  Once I do that, it seems to work.

The interesting thing is that it doesn't happen every time there is a
Unix/DOS file type change, so I don't know if it will work for you or
not.  While I have not dug into the source code (for this problem,
anyway), the fact that my files tend to truncate at 65536 bytes seems
suggestive of a line-length limitation.


Hope this helps,

Richard.

On Tue, Jun 19, 2012 at 9:16 AM, Wagemans, Peter <peter DOT wagemans AT kpn DOT com> wrote:
>
>
> For many years I have been using Emacs and RCS version control for
> individual simple notes and org-mode text files, with a habit of
> frequent check-in and check-out to save units of work. On Windows the
> RCS implementation is from Cygwin.
>
> Over the last months I have encountered several cases where check-in,
> check-out resulted in a work file truncated at exactly 64kiB and an
> inconsistent RCS file. Recovery from backup was necessary. Since both
> files were destroyed, I was unable to reproduce the problem.
>
> Now I seem to have found an example with a reconstructed work file
> that seems to systematically show the error (on my system) when
> checked in to an older backup RCS file.
>
> Problem aspects:
>
>  - The check-in reduces the size of the RCS file. It maintains the
>   version history and delta scripts, but the content of the latest
>   version is truncated to 64kiB (in the cases I encountered). [The
>   size of the latest version as stored within the RCS file is a bit
>   bigger since '@'-characters are doubled.]
>
>  - This makes the RCS file inconsistent: the edit scripts to recreate
>   older versions refer to line numbers that no longer exist.
>
>  - Since the problem also occurs on the command line, Emacs is not
>   part of the problem, just the way I encountered it.
>
>  - In my problem cases, the RCS files were not very small, up to
>   several MiB in size, usually also with modifications "in the
>   middle", not just extra content at the end. This is just for
>   information; I have no evidence whether any of this is relevant to
>   the problem.
>
>  - On Windows 7 64-bit and Vista 32-bit, I have seen the problem with
>   Cygwin rcs-5.8-1, so far not with rcs-5.7-11 (switching back and
>   forth several times with Cygwin setup.exe).
>
>  - On the example files, the GNU rcs 5.8.1 distribution compiled on
>   OpenSuSE 11.4 64-bit does the check-in OK. The same code base
>   configured and built on Windows 7, 64-bit under Cygwin produces an
>   inconsistent RCS file upon check-in. So it is probably not a pure
>   RCS bug; it seems dependent on the Cygwin environment.
>
> Attached is an archive with a template directory with a checked out
> work file and two directories after check-in, one successful (rcs
> package 5.7-11) and one not (rcs package 5.8-1). To reproduce the
> problem, copy the template directory tree, place your user name in the
> lock section of the RCS file blind.org,v:
>
>        xxxxxxxxx:1.100; strict;
>
> instead of 'xxxxxxxxx' and then do a check-in with ci.
>
> The attached cygcheck output is for Windows 7 64-bit, edited for
> confidentiality.
>
> Alphanumeric content characters in the example files have been
> replaced with the character 'x'.
>
> Now I'm wondering how to proceed with this problem (apart from
> reverting to rcs 5.7):
>
>  - Have other people encountered this kind of problem?
>
>  - Can other people reproduce the problem with my example file?
>
>  - Is there a known solution?
>
>  - If not, how can the problem be tracked down and solved?
>
>
> Regards,
>
> Peter Wagemans
>
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019