summaryrefslogtreecommitdiff
path: root/sys/isofs/udf/udf_vnops.c
diff options
context:
space:
mode:
authorMatthew Dempsky <matthew@cvs.openbsd.org>2012-06-20 17:30:23 +0000
committerMatthew Dempsky <matthew@cvs.openbsd.org>2012-06-20 17:30:23 +0000
commite3751797b5afd2a18ab6175ce166111383bf99b5 (patch)
treef8cbc586974f22efee2e9aa738f3f6e29044aa3f /sys/isofs/udf/udf_vnops.c
parent159f5470d216e7cd95c64dc10d61be4b3eab2ac2 (diff)
Cleanup our filesystem pathconf() code a little bit to make it easier
to diff against FreeBSD's. From Brad; no object file change on amd64.
Diffstat (limited to 'sys/isofs/udf/udf_vnops.c')
-rw-r--r--sys/isofs/udf/udf_vnops.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/sys/isofs/udf/udf_vnops.c b/sys/isofs/udf/udf_vnops.c
index bc1094c5bd2..4f77dd05644 100644
--- a/sys/isofs/udf/udf_vnops.c
+++ b/sys/isofs/udf/udf_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: udf_vnops.c,v 1.44 2011/07/04 20:35:35 deraadt Exp $ */
+/* $OpenBSD: udf_vnops.c,v 1.45 2012/06/20 17:30:22 matthew Exp $ */
/*
* Copyright (c) 2001, 2002 Scott Long <scottl@freebsd.org>
@@ -392,23 +392,27 @@ udf_ioctl(void *v)
static int
udf_pathconf(struct vop_pathconf_args *a)
{
+ int error = 0;
switch (ap->a_name) {
case _PC_LINK_MAX:
*ap->a_retval = 65535;
- return (0);
+ break;
case _PC_NAME_MAX:
*ap->a_retval = NAME_MAX;
- return (0);
+ break;
case _PC_PATH_MAX:
*ap->a_retval = PATH_MAX;
- return (0);
+ break;
case _PC_NO_TRUNC:
*ap->a_retval = 1;
- return (0);
+ break;
default:
- return (EINVAL);
+ error = EINVAL;
+ break;
}
+
+ return (error);
}
#endif