Source-Changes-HG archive

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

[src/trunk]: src/sys/compat/svr4 return the namemax from the bsd statvfs whic...



details:   https://anonhg.NetBSD.org/src/rev/2d5735f40f1f
branches:  trunk
changeset: 769919:2d5735f40f1f
user:      christos <christos%NetBSD.org@localhost>
date:      Tue Sep 27 00:52:55 2011 +0000

description:
return the namemax from the bsd statvfs which is filesystem dependent, not
a random value.

diffstat:

 sys/compat/svr4/svr4_misc.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (36 lines):

diff -r 9b72752ff65d -r 2d5735f40f1f sys/compat/svr4/svr4_misc.c
--- a/sys/compat/svr4/svr4_misc.c       Tue Sep 27 00:36:49 2011 +0000
+++ b/sys/compat/svr4/svr4_misc.c       Tue Sep 27 00:52:55 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: svr4_misc.c,v 1.154 2010/11/30 10:43:02 dholland Exp $  */
+/*     $NetBSD: svr4_misc.c,v 1.155 2011/09/27 00:52:55 christos Exp $  */
 
 /*-
  * Copyright (c) 1994, 2008 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: svr4_misc.c,v 1.154 2010/11/30 10:43:02 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: svr4_misc.c,v 1.155 2011/09/27 00:52:55 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1076,7 +1076,7 @@
                sfs->f_flag |= SVR4_ST_RDONLY;
        if (bfs->f_flag & MNT_NOSUID)
                sfs->f_flag |= SVR4_ST_NOSUID;
-       sfs->f_namemax = MAXNAMLEN;
+       sfs->f_namemax = bfs->f_namemax;
        memcpy(sfs->f_fstr, bfs->f_fstypename, sizeof(sfs->f_fstr)); /* XXX */
        memset(sfs->f_filler, 0, sizeof(sfs->f_filler));
 
@@ -1108,7 +1108,7 @@
                sfs->f_flag |= SVR4_ST_RDONLY;
        if (bfs->f_flag & MNT_NOSUID)
                sfs->f_flag |= SVR4_ST_NOSUID;
-       sfs->f_namemax = MAXNAMLEN;
+       sfs->f_namemax = bfs->f_namemax;
        memcpy(sfs->f_fstr, bfs->f_fstypename, sizeof(sfs->f_fstr)); /* XXX */
        memset(sfs->f_filler, 0, sizeof(sfs->f_filler));
 



Home | Main Index | Thread Index | Old Index