-/*
- * $Source$
- * $Author$
- * $Header$
+/* $Id$
+ *
+ * Deal with NFS partition types
*
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- * <mit-copyright.h>.
+ * Copyright (C) 1987-1998 by the Massachusetts Institute of Technology
+ * For copying and distribution information, please see the file
+ * <mit-copyright.h>.
*
*/
-#ifndef lint
-static char *rcsid_nfsparttype_c = "$Header$";
-#endif
-
#include <mit-copyright.h>
#include <moira.h>
+
#include <stdio.h>
-#include <string.h>
-#include <ctype.h>
#include <stdlib.h>
+#include <string.h>
-extern char *strsave();
-extern char *strtrim();
+RCSID("$Header$");
struct pair {
int type;
char *format_filesys_type(char *fs_status)
{
char buf[BUFSIZ];
- register struct pair *pp;
+ struct pair *pp;
int n_names = 0;
int stat = atoi(fs_status);
}
if (!n_names)
strcpy(buf, "none");
- return strsave(buf);
+ return strdup(buf);
}
/*
*/
char *parse_filesys_type(char *fs_type_name)
{
- register struct pair *pp;
- register char *cp = fs_type_name;
+ struct pair *pp;
+ char *cp = fs_type_name;
char temp[BUFSIZ];
int flags = 0;
}
while (cp);
sprintf(temp, "%d", flags);
- return strsave(temp);
+ return strdup(temp);
}