William A. Rowe, Jr. wrote: >I'm sorry... this patch dir not come through to [EMAIL PROTECTED] for me today >(although I watched for it...) but it's simply WRONG. > > > >At 07:04 PM 12/17/2002, =?UTF-8?B?QnJhbmtvIMSMaWJlag==?= wrote: > > >>>--- apr/file_io/unix/dir.c 15 Dec 2002 05:17:51 -0000 1.69 >>>+++ apr/file_io/unix/dir.c 17 Dec 2002 00:49:35 -0000 >>>@@ -218,10 +218,10 @@ >>> return ret; >>> } >>> >>>-#ifdef DIRENT_INODE >>>+#ifndef DIRENT_INODE >>> wanted &= ~APR_FINFO_INODE; >>>#endif >>> >>> > >Old logic; if we have an INODE from dirent, we don't care that we >want an INODE from stat() because we already have the INODE. > >New Logic: if we don't have an INODE, we won't ask for an INODE >from stat(). > >I'm sorry, but that's just broken. >' >Please revert and (re)post the original description of the problem. > >If you pass APR_FINFO_TYPE | APR_FINFO_INDOE | APR_FINFO_NAME >that is *ALL* you are promised... we do NOT stat for info you don't ask for. > >Bill >
Here's the original report: >Philip Martin <[EMAIL PROTECTED]> writes: > > > >>> Eeek! >>> >>> I've just upgraded to apache/apr/apr-util to HEAD and now I can >>> reproduce this. >>> >>> $ svnadmin create repo >>> $ svn mkdir file://`pwd`/repo/foo >>> $ svn co file://`pwd`/repo wc >>> $ svn up wc >>> ../svn/subversion/libsvn_wc/adm_crawler.c:315: (apr_err=155000, src_err=0) >>> svn: Obstructed update >>> svn: The entry 'bar' is no longer a directory, >>> which prevents proper updates. >>> Please remove this entry and try updating again. >> >> > >Looks like a recent apr change causes apr_dir_read to fail to return >all the requested information. I don't know if this is complete from >an apr point of view, but it's sufficient to get Subversion working on >my glibc 2.2.5 Linux machine. > > >Index: apr/file_io/unix/dir.c >=================================================================== >RCS file: /home/cvspublic/apr/file_io/unix/dir.c,v >retrieving revision 1.69 >diff -u -r1.69 dir.c >--- apr/file_io/unix/dir.c 15 Dec 2002 05:17:51 -0000 1.69 >+++ apr/file_io/unix/dir.c 17 Dec 2002 00:49:35 -0000 >@@ -218,10 +218,10 @@ > return ret; > } > >-#ifdef DIRENT_INODE >+#ifndef DIRENT_INODE > wanted &= ~APR_FINFO_INODE; > #endif >-#ifdef DIRENT_TYPE >+#ifndef DIRENT_TYPE > wanted &= ~APR_FINFO_TYPE; > #endif > > -- Philip Martin > Obviously, the type at least did not make it into the fle info. Looking at this code again, the patch may indeed be wrong; but I find it really, really hard to follow that code. In fact, I can't understand it at all. If you can enlighten me about what's happening there, I may be able to come up with a better patch. I reverted my change, but be aware that apr_dir_read is currently broken. It simply does not work on Linux with a redent glibc, it also doesn't work in Solaris 7 (at least for me), etc. etc. It must be fixed. -- Brane Äibej <[EMAIL PROTECTED]> http://www.xbc.nu/brane/
