This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Remote dirs in fhandler_disk_file::fstat()?


Hi there,

I have been reading cygwin code trying to understand it better, hoping
to contribute to it later.  Pretty cool treasure trove of Windows code
I must say.  I have a question on fhandler_disk_file.cc (rev 1.9).  In
fhandler_disk_file::fstat(), line 114 onwards there is this code:

  else if (pc->exists ())
    {
      /* Unfortunately, the above open may fail if the file exists, though.
         So we have to care for this case here, too. */
      WIN32_FIND_DATA wfd;
      HANDLE handle;
      buf->st_nlink = 1;
      if (pc->isdir () && pc->isremote ())
        buf->st_nlink = num_entries (pc->get_win32 ());

Should that be `... && ! pc->isremote ())'?  At least the code above,
various ChangeLog and cvs log messages and the message from Corinna
(http://www.cygwin.com/ml/cygwin-developers/2000-03/msg00091.html)
suggest so.  If so, I'll be happy to whip up a patch.

(I do not yet have a suitable cygwin development environment, so I can't
test code changes myself. I am hoping to set this up in the next couple
of months so I can step through the code in gdb to understand it better.
Hence apologies for this somewhat academic question.)

//lat
-- 
Real programmers like vending machine popcorn.  Coders pop it in
the microwave oven.  Real programmers use the heat given off by
the cpu.  They can tell what job is running just by listening to
the rate of popping.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]