* include/paths.h (_PATH_MNTTAB): Define.

(_PATH_MOUNTED): Define.
	* include/mntent.h: Include paths.h.  Define MNTTAB and MOUNTED as their
	paths.h equivalents.  Add comment.
This commit is contained in:
Corinna Vinschen 2010-02-02 11:17:54 +00:00
parent fc6a0dc849
commit fac3c73ba0
3 changed files with 19 additions and 3 deletions

View File

@ -1,3 +1,10 @@
2010-02-02 Corinna Vinschen <corinna@vinschen.de>
* include/paths.h (_PATH_MNTTAB): Define.
(_PATH_MOUNTED): Define.
* include/mntent.h: Include paths.h. Define MNTTAB and MOUNTED as their
paths.h equivalents. Add comment.
2010-02-01 Christopher Faylor <me+cygwin@cgf.cx> 2010-02-01 Christopher Faylor <me+cygwin@cgf.cx>
* dcrt0.cc (atexit_lock): Delete. * dcrt0.cc (atexit_lock): Delete.

View File

@ -1,6 +1,6 @@
/* mntent.h /* mntent.h
Copyright 1996, 1998, 1999, 2000, 2001, 2006, 2009 Red Hat, Inc. Copyright 1996, 1998, 1999, 2000, 2001, 2006, 2009, 2010 Red Hat, Inc.
This file is part of Cygwin. This file is part of Cygwin.
@ -15,6 +15,8 @@ details. */
extern "C" { extern "C" {
#endif #endif
#include <paths.h>
struct mntent struct mntent
{ {
char *mnt_fsname; char *mnt_fsname;
@ -32,12 +34,17 @@ struct mntent *getmntent (FILE *__filep);
int endmntent (FILE *__filep); int endmntent (FILE *__filep);
#endif #endif
/* The following two defines are deprecated. Use the equivalent
names from paths.h instead. */
#ifndef MNTTAB
#define MNTTAB _PATH_MNTTAB
#endif
/* This next file does exist, but the implementation of these /* This next file does exist, but the implementation of these
functions does not actually use it. functions does not actually use it.
However, applications need the define to pass to setmntent(). However, applications need the define to pass to setmntent().
*/ */
#ifndef MOUNTED #ifndef MOUNTED
#define MOUNTED "/etc/mtab" #define MOUNTED _PATH_MOUNTED
#endif #endif
#ifdef __cplusplus #ifdef __cplusplus

View File

@ -1,6 +1,6 @@
/* paths.h /* paths.h
Copyright 2001, 2002, 2003 Red Hat, Inc. Copyright 2001, 2002, 2003, 2010 Red Hat, Inc.
This file is part of Cygwin. This file is part of Cygwin.
@ -19,6 +19,8 @@ details. */
#define _PATH_LASTLOG "/var/log/lastlog" #define _PATH_LASTLOG "/var/log/lastlog"
#define _PATH_MAN "/usr/share/man" #define _PATH_MAN "/usr/share/man"
#define _PATH_MEM "/dev/mem" #define _PATH_MEM "/dev/mem"
#define _PATH_MNTTAB "/etc/fstab"
#define _PATH_MOUNTED "/etc/mtab"
#define _PATH_STDPATH "/bin:/usr/sbin:/sbin" #define _PATH_STDPATH "/bin:/usr/sbin:/sbin"
#define _PATH_TMP "/tmp/" #define _PATH_TMP "/tmp/"
#define _PATH_TTY "/dev/tty" #define _PATH_TTY "/dev/tty"