From owner-freebsd-current Thu Dec 24 08:04:57 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA16534 for freebsd-current-outgoing; Thu, 24 Dec 1998 08:04:57 -0800 (PST) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from janus.syracuse.net (janus.syracuse.net [205.232.47.15]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id IAA16526 for ; Thu, 24 Dec 1998 08:04:55 -0800 (PST) (envelope-from green@unixhelp.org) Received: from localhost (green@localhost) by janus.syracuse.net (8.8.8/8.8.7) with ESMTP id LAA19362 for ; Thu, 24 Dec 1998 11:04:45 -0500 (EST) Date: Thu, 24 Dec 1998 11:04:45 -0500 (EST) From: Brian Feldman X-Sender: green@janus.syracuse.net To: current@FreeBSD.ORG Subject: revoke of fifos Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG revoke(2) on VFIFO types is broken now, leading to stranded mbuf's. I suppose bde is tracking this down, but for now, why don't we return EINVAL in revoke(2)? /usr/src/sys/kern/vfs_syscalls.c: unmodified, readonly: line 2912 of 3038 [95%] if (vp->v_type == VFIFO) { error = EINVAL; goto out; } That should temporarily work to prevent the following easily reproducible mbuf- starvation crash case: (as any user) mkfifo fifo while true; do dd if=fifo of=/dev/null & dd if=/dev/zero of=fifo & ./revoke \ fifo; done where revoke.c is on the lines of #include #include int main(int argc, char **argv) { if (!argv[1]) exit(1); printf("revoke(%s) == %d\n", argv[1], revoke(argv[1])); exit(0); } Brian Feldman _ __ ___ ___ ___ green@unixhelp.org _ __ ___ | _ ) __| \ http://www.freebsd.org/ _ __ ___ ____ | _ \__ \ |) | FreeBSD: The Power to Serve! _ __ ___ ____ _____ |___/___/___/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message