Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.sbin/makefs/msdos the max msdos file size is less than s...



details:   https://anonhg.NetBSD.org/src/rev/556cd40c0ad7
branches:  trunk
changeset: 784388:556cd40c0ad7
user:      christos <christos%NetBSD.org@localhost>
date:      Sun Jan 27 16:03:15 2013 +0000

description:
the max msdos file size is less than size_t so don't bother checking against it.

diffstat:

 usr.sbin/makefs/msdos/msdosfs_vnops.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r d95dd763016f -r 556cd40c0ad7 usr.sbin/makefs/msdos/msdosfs_vnops.c
--- a/usr.sbin/makefs/msdos/msdosfs_vnops.c     Sun Jan 27 15:35:45 2013 +0000
+++ b/usr.sbin/makefs/msdos/msdosfs_vnops.c     Sun Jan 27 16:03:15 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: msdosfs_vnops.c,v 1.7 2013/01/27 15:35:45 christos Exp $ */
+/*     $NetBSD: msdosfs_vnops.c,v 1.8 2013/01/27 16:03:15 christos Exp $ */
 
 /*-
  * Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.
@@ -51,7 +51,7 @@
 #endif
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: msdosfs_vnops.c,v 1.7 2013/01/27 15:35:45 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: msdosfs_vnops.c,v 1.8 2013/01/27 16:03:15 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/mman.h>
@@ -423,7 +423,7 @@
                return 0;
 
        /* Don't bother to try to write files larger than the fs limit */
-       if (st->st_size > (off_t)min(MSDOSFS_FILESIZE_MAX,__SIZE_MAX__)) {
+       if (st->st_size > MSDOSFS_FILESIZE_MAX) {
                errno = EFBIG;
                return -1;
        }



Home | Main Index | Thread Index | Old Index