diff options
author | Christopher Faylor <me@cgf.cx> | 2001-09-04 05:09:39 +0400 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2001-09-04 05:09:39 +0400 |
commit | f90e39b55e112ba76f304f7e164bd60f25433285 (patch) | |
tree | 78c8ed7d69b7e8f32c7dd0e74244d3306a9f5f52 /winsup/utils/mount.cc | |
parent | bee722a5e728dac0e117166d42870103c00ffcbb (diff) |
* mount.cc (mount_commands): Don't write /cygdrive/u mount points.
Diffstat (limited to 'winsup/utils/mount.cc')
-rw-r--r-- | winsup/utils/mount.cc | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/winsup/utils/mount.cc b/winsup/utils/mount.cc index 75b45d2bd..31f4aed16 100644 --- a/winsup/utils/mount.cc +++ b/winsup/utils/mount.cc @@ -265,20 +265,23 @@ mount_commands (void) // write mount commands for user and system mount points while ((p = getmntent (m)) != NULL) { - strcpy(opts, " -f"); - if (p->mnt_type[0] == 'u') - strcat (opts, " -u"); - else if (p->mnt_type[0] == 's') - strcat (opts, " -s"); - if (p->mnt_opts[0] == 'b') - strcat (opts, " -b"); - else if (p->mnt_opts[0] == 't') - strcat (opts, " -t"); - if (strstr (p->mnt_opts, ",exec")) - strcat (opts, " -x"); - while ((c = strchr (p->mnt_fsname, '\\')) != NULL) - *c = '/'; - printf (format_mnt, opts, p->mnt_fsname, p->mnt_dir); + // Only list non-cygdrives + if (!strstr (p->mnt_opts, ",noumount")) { + strcpy(opts, " -f"); + if (p->mnt_type[0] == 'u') + strcat (opts, " -u"); + else if (p->mnt_type[0] == 's') + strcat (opts, " -s"); + if (p->mnt_opts[0] == 'b') + strcat (opts, " -b"); + else if (p->mnt_opts[0] == 't') + strcat (opts, " -t"); + if (strstr (p->mnt_opts, ",exec")) + strcat (opts, " -x"); + while ((c = strchr (p->mnt_fsname, '\\')) != NULL) + *c = '/'; + printf (format_mnt, opts, p->mnt_fsname, p->mnt_dir); + } } endmntent (m); |