delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/09/21/14:40:36

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Sat, 21 Sep 2002 11:40:25 -0700 (Pacific Daylight Time)
From: Michael A Chase <mchase AT ix DOT netcom DOT com>
Subject: Re: df --local
To: cygwin AT cygwin DOT com, Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Message-ID: <Mahogany-0.64.2-284-20020921-114025.00@MCHASE-COMPAQ>
MIME-Version: 1.0
References: <Pine DOT GSO DOT 4 DOT 44 DOT 0209211238040 DOT 15469-100000 AT slinky DOT cs DOT nyu DOT edu>
In-Reply-To: <Pine.GSO.4.44.0209211238040.15469-100000@slinky.cs.nyu.edu>

On Sat, 21 Sep 2002 12:46:13 -0400 (EDT) Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu> wrote:

> On Sat, 21 Sep 2002, egor duda wrote:
> 
> > Friday, 20 September, 2002 Rob Brown rob AT mp3 DOT com wrote:
> >
> > RB> OK, that will *mostly* work except for the cdrom drive issue.
> >
> > The proper way is to convert path to win32 form and then use
> > GetDriveType() and GetVolumeInformation() APIs.
> 
> This is related to the question I asked on the cygwin-developers list (
> http://www.cygwin.com/ml/cygwin-developers/2002-09/msg00078.html ).  Maybe
> people can discuss it here...
> 
> Basically, Cygwin's getmntent() returns either "user" or "system" as the
> fstype, whereas on other systems (Linux, etc) the fstype is the type of
> the filesystem (cdrom, nfs, local, etc).  I was proposing a change to make
> the user/system distinction part of mnt_opts, and set the type field to
> whatever's returned by GetVolumeInformation().  This method is called in
> path.cc anyway, to distinguish Samba filesystems...

It sounds like a good idea to me.  I found the current values being used in
a few places.

newlib/libc/sys/linux/fstab.c
   Just passing the value through.

newlib/libc/sys/linux/mntent_r.c
   Extracting the value from a string.
   I'm not sure where the string is created, possibly path.cc.

winsup/cygwin/path.cc
   Converts bits in flags to string ("user" or "system").

winsup/utils/cygcheck.cc
   Prints whatever it finds in mnt->mnt_type.

winsup/utils/mount.cc
   Uses current values of mnt_type several places.

winsup/utils/path.cc
   Converts m->issys to string ("user" or "system").

winsup/utils/umount.cc
   Tests p->mnt_type for current values.

It looks like the main confusion would come from people parsing the output
from cygcheck or mount and expecting the current values of "user" or
"system".

-- 
Mac :})
** I normally forward private questions to the appropriate mail list. **
Ask Smarter: http://www.tuxedo.org/~esr/faqs/smart-questions.html
Give a hobbit a fish and he eats fish for a day.
Give a hobbit a ring and he eats fish for an age.


--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019