From 27e0d2b78b28854e6f85928943bb7eaab485d334 Mon Sep 17 00:00:00 2001 From: christos Date: Tue, 17 Jul 2007 20:17:52 +0000 Subject: [PATCH] kill MFSNAMELEN --- sbin/umount/umount.c | 7 ++++--- sys/arch/mvme68k/stand/installboot/installboot.c | 6 +++--- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/sbin/umount/umount.c b/sbin/umount/umount.c index 593e2f4af3c6..9dae78ab9f67 100644 --- a/sbin/umount/umount.c +++ b/sbin/umount/umount.c @@ -1,4 +1,4 @@ -/* $NetBSD: umount.c,v 1.39 2007/07/16 17:06:55 pooka Exp $ */ +/* $NetBSD: umount.c,v 1.40 2007/07/17 20:17:52 christos Exp $ */ /*- * Copyright (c) 1980, 1989, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1989, 1993\n\ #if 0 static char sccsid[] = "@(#)umount.c 8.8 (Berkeley) 5/8/95"; #else -__RCSID("$NetBSD: umount.c,v 1.39 2007/07/16 17:06:55 pooka Exp $"); +__RCSID("$NetBSD: umount.c,v 1.40 2007/07/17 20:17:52 christos Exp $"); #endif #endif /* not lint */ @@ -238,7 +238,8 @@ umountfs(const char *name, const char **typelist, int raw) return 1; (void)memset(&hints, 0, sizeof hints); - if (!strncmp(type, MOUNT_NFS, MFSNAMELEN)) { + if (!strncmp(type, MOUNT_NFS, + sizeof(((struct statvfs *)NULL)->f_fstypename))) { char *delimp; /* look for host:mountpoint */ if ((delimp = strrchr(name, ':')) != NULL) { diff --git a/sys/arch/mvme68k/stand/installboot/installboot.c b/sys/arch/mvme68k/stand/installboot/installboot.c index f37e14f8d2a9..198e4007e7a4 100644 --- a/sys/arch/mvme68k/stand/installboot/installboot.c +++ b/sys/arch/mvme68k/stand/installboot/installboot.c @@ -1,4 +1,4 @@ -/* $NetBSD: installboot.c,v 1.11 2005/12/11 12:18:19 christos Exp $ */ +/* $NetBSD: installboot.c,v 1.12 2007/07/17 20:18:58 christos Exp $ */ /*- * Copyright (c) 1998 The NetBSD Foundation, Inc. @@ -280,8 +280,8 @@ int devfd; if (fstatvfs(fd, &statvfsbuf) != 0) err(1, "statfs: %s", boot); - if (strncmp(statvfsbuf.f_fstypename, "ffs", MFSNAMELEN) && - strncmp(statvfsbuf.f_fstypename, "ufs", MFSNAMELEN) ) { + if (strncmp(statvfsbuf.f_fstypename, "ffs", sizeof(statvfsbuf.f_fstypename)) && + strncmp(statvfsbuf.f_fstypename, "ufs", sizeof(statvfsbuf.f_fstypename)) ) { errx(1, "%s: must be on an FFS filesystem", boot); }