From owner-freebsd-doc Mon May 25 13:55:22 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id NAA03091 for freebsd-doc-outgoing; Mon, 25 May 1998 13:55:22 -0700 (PDT) (envelope-from owner-freebsd-doc@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id NAA03083 for ; Mon, 25 May 1998 13:55:17 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id NAA04112; Mon, 25 May 1998 13:50:01 -0700 (PDT) Date: Mon, 25 May 1998 13:50:01 -0700 (PDT) Message-Id: <199805252050.NAA04112@freefall.freebsd.org> To: doc@FreeBSD.ORG From: Stefan Eggers Subject: Re: docs/6753: getvfsent(3) example is out of date Reply-To: Stefan Eggers Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR docs/6753; it has been noted by GNATS. From: Stefan Eggers To: FreeBSD-gnats-submit@FreeBSD.ORG, doc@FreeBSD.ORG Cc: seggers@semyam.dinoco.de Subject: Re: docs/6753: getvfsent(3) example is out of date Date: Mon, 25 May 1998 22:47:33 +0200 Sorry! I killed one line too much. :-( Here is the - hopefully now correct - diff output: *** getvfsent.3.ORIG Fri Feb 28 06:49:18 1997 --- getvfsent.3 Mon May 25 22:39:13 1998 *************** *** 140,160 **** vfc = getvfsbyname("cd9660"); if(!vfc && vfsisloadable("cd9660")) { ! if(vfsload("cd9660")) ! err(1, "vfsload(cd9660)"); ! endvfsent(); /* flush cache */ vfc = getvfsbyname("cd9660"); } ! mount(vfc ? vfc->vfc_index : MOUNT_CD9660, /* more arguments */ .Ed - The odd conditional in the call to - .Xr mount 2 - is present for compatibility with old, non-LKM cognizant kernels, and - will be removed (along with all vestiges of - .Dv MOUNT_* ) - in a future release. .Sh RETURN VALUES The .Fn getvfsbyname , --- 140,158 ---- vfc = getvfsbyname("cd9660"); if(!vfc && vfsisloadable("cd9660")) { ! if(vfsload("cd9660")) { ! err(EX_OSERR, "vfsload(cd9660)"); ! } ! endvfsent(); /* flush cache */ vfc = getvfsbyname("cd9660"); } + if (!vfc) + errx(EX_OSERR, "cd9660 filesystem not available"); ! if (mount(vfc->vfc_index, dir, mntflags, &args) < 0) ! err(EX_OSERR, "%s", dev); .Ed .Sh RETURN VALUES The .Fn getvfsbyname , To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message