/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*
* Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include <ctype.h>
static int mntdigit(char **p);
extern char *calloc();
struct mnttab *
_mnt()
{
if (mntp == 0)
return (mntp);
}
static char *
mntstr(p)
register char **p;
{
char *cp = *p;
char *retstr;
cp++;
cp++;
if (*cp)
{
*cp = '\0';
cp++;
}
*p = cp;
return (retstr);
}
static int
mntdigit(p)
register char **p;
{
register int value = 0;
char *cp = *p;
cp++;
{
value *= 10;
}
cp++;
if (*cp)
{
*cp = '\0';
cp++;
}
*p = cp;
return (value);
}
static int
{
char *cp;
do
{
{
return (EOF);
}
} while (*cp == '#');
if (*cp == '\0')
return (1);
if (*cp == '\0')
return (2);
if (*cp == '\0')
return (3);
if (*cp == '\0')
return (4);
return (5);
}
FILE *
char *fname;
char *flag;
{
{
return (NULL);
}
{
{
{
return (NULL);
}
break;
}
}
return (mnttabp);
}
int
{
if (mnttabp)
{
}
return (1);
}
/*
* #ifdef NOWAY
* int getmntent (mnttabp, mp)
* FILE *mnttabp;
* struct mnttab *mp;
* {
* int nfields;
*
* if (mnttabp == 0)
* return (-1);
*
* if (_mnt() == 0)
* return (-1);
*
* nfields = mnttabscan(mnttabp, mntp);
*
* if (nfields == EOF || nfields != 5)
* return (-1);
*
* mp = mntp;
*
* return ( 0 );
* }
* #endif
*
*
* #ifdef NOWAY
* struct mnttab *
* getmntent(mnttabp)
* FILE *mnttabp;
* {
* int nfields;
*
* if (mnttabp == 0)
* return ((struct mnttab *)0);
* if (_mnt() == 0)
* return ((struct mnttab *)0);
* nfields = mnttabscan(mnttabp, mntp);
* if (nfields == EOF || nfields != 5)
* return ((struct mnttab *)0);
* return (mntp);
* }
* #endif
*/
/*
* addmntent(mnttabp, mnt)
* FILE *mnttabp;
* register struct mnttab *mnt;
*
* if (fseek(mnttabp, 0L, 2) < 0)
* return (1);
* if (mnt == (struct mnttab *)0)
* return (1);
* if (mnt->mnt_special == NULL || mnt->mnt_mountp == NULL ||
* mnt->mnt_fstype == NULL || mnt->mnt_mntopts == NULL)
* return (1);
*
* mntprtent(mnttabp, mnt);
* return (0);
* }
*/
static int
{
return(0);
}