I just noticed that our opendir() implementation sometimes reports 
the wrong errno when it fails.  This bug is something I introduced in 
the 5.7 stream and has never been in a production release so I don't 
see much point in documenting the change.  In any case, the patch 
here prevents underlying causes such as ENOENT and EINVAL from being 
overridden with EACCES.

--- vms/vms.c;-0        Thu Jun 13 21:11:50 2002
+++ vms/vms.c   Mon Jul  1 19:32:36 2002
@@ -4721,7 +4721,7 @@
      * accurately report whether it's a directory.
      */
     if (!cando_by_name(S_IRUSR,0,dir)) {
-      set_errno(EACCES); set_vaxc_errno(RMS$_PRV);
+      /* cando_by_name has already set errno */
       return NULL;
     }
     if (flex_stat(dir,&sb) == -1) return NULL;
[end of patch]
-- 
________________________________________
Craig A. Berry
mailto:[EMAIL PROTECTED]

"... getting out of a sonnet is much more
 difficult than getting in."
                 Brad Leithauser

Reply via email to