Bug 10374

Summary: spurious "error reading current directory" errors
Product: [Retired] Red Hat Linux Reporter: Jonathan Kamens <jik>
Component: cvsAssignee: David Lawrence <dkl>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 6.2   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2000-04-24 20:48:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
patch to initialize errno when necessary none

Description Jonathan Kamens 2000-03-27 19:05:47 UTC
Because readdir returns NULL when all directory entries have been read OR
there was an error reading the directory, cvs sets errno to 0 before each
call to readdir and then checks if it is non-zero afterwards to determine
if an error occurred.

Unfortunately, there are a few places in which cvs forgets to set errno to
0 when it should have, and as a result, it can sometimes report spurious
"error reading current directory" errors.  Yes, I actually saw this happen
once, although I can't replicate it easily in a small sample tree, and the
patch I'm about to attach to this bug does in fact make the spurious errors
I saw go away.

Y'all should submit this back to the cvs maintainers as well as putting it
into the redhat package until they incorporate it into the master tree.

Comment 1 Jonathan Kamens 2000-03-27 19:09:59 UTC
Created attachment 162 [details]
patch to initialize errno when necessary

Comment 2 Jim Kingdon 2000-04-24 20:47:59 UTC
Some of these are already fixed in CVS 1.10.8, if memory serves.

Comment 3 Nalin Dahyabhai 2000-07-10 20:44:23 UTC
Slightly modified versions of these changes are being rolled into
cvs-1.10.8-7 and later.