From owner-freebsd-hackers Thu Nov 2 15:13:55 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from whizkidtech.net (r41.bfm.org [216.127.220.137]) by hub.freebsd.org (Postfix) with ESMTP id 92A7737B4D7 for ; Thu, 2 Nov 2000 15:13:49 -0800 (PST) Received: (from adam@localhost) by whizkidtech.net (8.9.2/8.9.2) id RAA00244; Thu, 2 Nov 2000 17:12:24 -0600 (CST) (envelope-from adam) Date: Thu, 2 Nov 2000 17:11:53 -0600 From: "G. Adam Stanislav" To: Dag-Erling Smorgrav Cc: Michael Bacarella , hackers@FreeBSD.ORG Subject: Re: Kernel calls, are they documented somewhere? Message-ID: <20001102171153.A228@whizkidtech.net> References: <20001101222558.A408@whizkidtech.net> <20001102001202.A14447@mmap.nyct.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0.1i In-Reply-To: ; from des@ofug.org on Thu, Nov 02, 2000 at 09:59:02AM +0100 Organization: Whiz Kid Technomagic X-URL: http://www.whizkidtech.net/ X-Castle: http://www.redprince.net/ X-Special-Effects: http://www.FilmSFX.com/ X-Operating-System: FreeBSD whizkidtech.net 3.1-RELEASE FreeBSD 3.1-RELEASE Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Thu, Nov 02, 2000 at 09:59:02AM +0100, Dag-Erling Smorgrav wrote: >Adam, it's really quite simple: if the carry flag is set, the syscall >failed, and the value returned is the errno (in your example, open(2) >returned 2, which is ENOENT, i.e. the file didn't exist). If it >succeeded, the value returned is the result (a file descriptor in >open(2)'s case). Aha! Thank you (and everyone else who answered). That did the trick. I just knew FreeBSD would use a simple and elegant solution, and this one is both. Thanks again! Adam -- Don't send me spam, I'm a vegetarian To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message