From owner-freebsd-hackers Mon Feb 26 14:23:45 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from guild.plethora.net (guild.plethora.net [205.166.146.8]) by hub.freebsd.org (Postfix) with ESMTP id E027037B65D for ; Mon, 26 Feb 2001 14:23:42 -0800 (PST) (envelope-from seebs@guild.plethora.net) Received: from guild.plethora.net (seebs@localhost.plethora.net [127.0.0.1]) by guild.plethora.net (8.10.1/8.10.1) with ESMTP id f1QMNg621729 for ; Mon, 26 Feb 2001 16:23:42 -0600 (CST) Message-Id: <200102262223.f1QMNg621729@guild.plethora.net> From: seebs@plethora.net (Peter Seebach) Reply-To: seebs@plethora.net (Peter Seebach) To: freebsd-hackers@freebsd.org Subject: Re: Setting memory allocators for library functions. In-reply-to: Your message of "Mon, 26 Feb 2001 19:18:57 -0300." Date: Mon, 26 Feb 2001 16:23:42 -0600 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message , Rik van Riel writes: >Rationale: >SIGSEGV for _user_ mistakes (process accesses wrong stuff) >SIGBUS for _system_ errors (ECC error, kernel messes up, ...) Actually, this is not canonically the distinction made. On a Unix PC, { int *a, c[2]; char *b; a = c; b = a; ++b; a = b; *a = 0; } would get SIGBUS, because it was a bus error. The error is not a segmentation fault; the memory written to is all legitimately available to the process. It is a bus error, because the data access is not possible on the bus. :) I think "the memory you thought you had actually doesn't exist anywhere" is more like a segmentation fault than a bus error. -s To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message