When trying to commit to a cvs branch after adding a new file I get this error
Assertion failed: key != NULL, file hash.c, line 317
Any idea how to fix it so I can check my code in?
both server and client are Linux
there are pre-commits involved
When trying to commit to a cvs branch after adding a new file I get this error
Assertion failed: key != NULL, file hash.c, line 317
Any idea how to fix it so I can check my code in?
both server and client are Linux
there are pre-commits involved
Perhaps there is some kind of pre-commit check on your repository, see here
Are you on Windows and did you rename a file to the same name with different case (e.g. MAKEFILE vs Makefile vs makefile)? CVS used to have a problem with this (and maybe still does?):
OSDir/mailarchive - Subject: Re: hash.c.312: findnode:
Manu writes:
I try to rename "makefile" to "Makefile" in my cvs tree, then:
cvs: hash.c:312: findnode: Assertion `key != ((void *)0)' failed.
cvs [server aborted]: received abort signal
CVS was never designed to cope with case insensitive file systems. It has been patched to the point where it mostly works, but there are still some places where it doesn't. This is one of them.
You might want to read the rest of the messages in the thread as well.
Not sure what the issue was but I solved it by going onto the server and deleting the file Attic/newfile.v in the repository and adding it again.
sleep-er writes:
Not sure what the issue was but I solved it by going onto the server and deleting the file Attic/newfile.v in the repository and adding it again.
The "Attic" is the place where deleted files go in CVS. At some point in the past, someone checked in newfile.v, and at some later point it was deleted, hence moved to the Attic.
By deleting the ,v file from the repository you corrupted older commits that included the file "newfile". Do not do this.
The correct way is to restore the deleted file, then replace its content by the new file.
According to http://www.cs.indiana.edu/~machrist/notes/cvs.html
To recover a file that has been removed from the repository, you essentially need to update that file to its last revision number (before it was actually deleted). For example:
cvs update -r 1.7 deleted_file
This will recover deleted_file in your working repository. To find deleted files and their last revision number, issue cvs log at the command prompt.
Edited in reply to comment to explain what the ,v file in the Attic means.