[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnu-arch-users] Re: patch: automatic remove the corrupt revlib revision
From: |
Stefan Monnier |
Subject: |
[Gnu-arch-users] Re: patch: automatic remove the corrupt revlib revision |
Date: |
Sun, 04 Dec 2005 12:08:16 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
> Corrupt revision libraries should be a rare exception, not a rule.
Yes, I actually have never seen it happen (probably because I stay clear of
stupid tricks like hardlinking into the revlib). But I've very often seen
inode-sig failures because inode numbers had changed for one reason or
another (backup/restore and things like that typically).
So maybe a better solution to the problem of tla complaining about
inode-sig-failure is to provide a "2nd chance" code which first checks
whether actual corruption really happened: if it did, then signal the error
somehow (including text describing how to remove the offending data),
otherwise re-snap the inode data.
To detect actual corruption, an MD5 checksum of the whole revision should
be enough.
BTW, I'd also recommend to make all the files and dirs inside a revlib
read-only.
Stefan