=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/quota/quota.c,v retrieving revision 1.19 retrieving revision 1.20 diff -c -r1.19 -r1.20 *** src/usr.bin/quota/quota.c 2002/02/17 19:42:31 1.19 --- src/usr.bin/quota/quota.c 2002/05/14 12:24:10 1.20 *************** *** 1,4 **** ! /* $OpenBSD: quota.c,v 1.19 2002/02/17 19:42:31 millert Exp $ */ /* * Copyright (c) 1980, 1990, 1993 --- 1,4 ---- ! /* $OpenBSD: quota.c,v 1.20 2002/05/14 12:24:10 fgsch Exp $ */ /* * Copyright (c) 1980, 1990, 1993 *************** *** 37,50 **** */ #ifndef lint ! static char copyright[] = "@(#) Copyright (c) 1980, 1990, 1993\n\ The Regents of the University of California. All rights reserved.\n"; #endif /* not lint */ #ifndef lint /*static char sccsid[] = "from: @(#)quota.c 8.1 (Berkeley) 6/6/93";*/ ! static char rcsid[] = "$OpenBSD: quota.c,v 1.19 2002/02/17 19:42:31 millert Exp $"; #endif /* not lint */ /* --- 37,51 ---- */ #ifndef lint ! static const char copyright[] = "@(#) Copyright (c) 1980, 1990, 1993\n\ The Regents of the University of California. All rights reserved.\n"; #endif /* not lint */ #ifndef lint /*static char sccsid[] = "from: @(#)quota.c 8.1 (Berkeley) 6/6/93";*/ ! static const char rcsid[] = ! "$OpenBSD: quota.c,v 1.20 2002/05/14 12:24:10 fgsch Exp $"; #endif /* not lint */ /* *************** *** 88,97 **** int alldigits(char *); int callaurpc(char *, int, int, int, xdrproc_t, void *, xdrproc_t, void *); - int main(int, char **); int getnfsquota(struct statfs *, struct fstab *, struct quotause *, long, int); ! struct quotause *getprivs(long id, int quotatype); int getufsquota(struct statfs *, struct fstab *, struct quotause *, long, int); void heading(int, u_long, const char *, const char *); --- 89,98 ---- int alldigits(char *); int callaurpc(char *, int, int, int, xdrproc_t, void *, xdrproc_t, void *); int getnfsquota(struct statfs *, struct fstab *, struct quotause *, long, int); ! struct quotause ! *getprivs(long id, int quotatype); int getufsquota(struct statfs *, struct fstab *, struct quotause *, long, int); void heading(int, u_long, const char *, const char *); *************** *** 177,182 **** --- 178,185 ---- exit(0); } /* NOTREACHED */ + + exit(1); } void *************** *** 229,235 **** } myuid = getuid(); if (pwd->pw_uid != myuid && myuid != 0) { ! warnx("%s (uid %u): permission denied", pwd->pw_name, pwd->pw_uid); return; } showquotas(USRQUOTA, pwd->pw_uid, pwd->pw_name); --- 232,239 ---- } myuid = getuid(); if (pwd->pw_uid != myuid && myuid != 0) { ! warnx("%s (uid %u): permission denied", pwd->pw_name, ! pwd->pw_uid); return; } showquotas(USRQUOTA, pwd->pw_uid, pwd->pw_name); *************** *** 472,478 **** setfsent(); for (i = 0; i < nfst; i++) { if (qup == NULL) { ! if ((qup = (struct quotause *)malloc(sizeof *qup)) == NULL) errx(2, "out of memory"); } if (strncmp(fst[i].f_fstypename, "nfs", MFSNAMELEN) == 0) { --- 476,483 ---- setfsent(); for (i = 0; i < nfst; i++) { if (qup == NULL) { ! if ((qup = ! (struct quotause *)malloc(sizeof *qup)) == NULL) errx(2, "out of memory"); } if (strncmp(fst[i].f_fstypename, "nfs", MFSNAMELEN) == 0) {