🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.unix.programmer
Article #1094

Re: Checking return values (was: Trojan Horses, NFS, etc.)

#1094
From: Ronald S H Khoo
Date: Fri, 26 Oct 1990 07:18
19 lines
1413 bytes
In article <3648@skye.ed.ac.uk> richard@aiai.UUCP (Richard Tobin) writes:

> Or else you must save and restore errno.  Is this guaranteed to work?

I had thought not, but apparently the answer is "yes" because 4.1.3
says that errno expands to a "modifiable lvalue" and 4.9.10.4 says that perror()
"maps the error number in the integer expression errno to an error message"

So I guess you're right.  OK.

In <8215:Oct2521:30:3890@kramden.acf.nyu.edu>,
Dan Bernstein <brnstnd@kramden.acf.nyu.edu> suggested using
sys_errlist[] which is not standard.  I suppose you can always provide
a strerror() written in terms of sys_errlist[] if you don't already have
strerror() [4.11.6.2].  Many people don't have strerror() which is why
I did not mention it previously.  (I have it, though)

-- 
ronald@robobar.co.uk +44 81 991 1142 (O) +44 71 229 7741 (H)
Technical Details
Message-ID: <1990Oct26.071834.6257@robobar.co.uk>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!know!zaphod.mps.ohio-state.edu!wuarchive!mit-eddie!bloom-beacon!eru!hagbard!sunic!mcsun!ukc!stl!robobar!ronald
References: <1990Oct24.193712.8693@athena.mit.edu> <1990Oct25.075856.4923@robobar.co.uk> <3648@skye.ed.ac.uk>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!know!zaphod.mps.ohio-state.edu!wuarchive!mit-eddie!bloom-beacon!eru!hagbard!sunic!mcsun!ukc!stl!robobar!ronald
From: ronald@robobar.co.uk (Ronald S H Khoo)
Newsgroups: comp.unix.programmer
Subject: Re: Checking return values (was: Trojan Horses, NFS, etc.)
Message-ID: <1990Oct26.071834.6257@robobar.co.uk>
Date: 26 Oct 90 07:18:34 GMT
References: <1990Oct24.193712.8693@athena.mit.edu> <1990Oct25.075856.4923@robobar.co.uk> <3648@skye.ed.ac.uk>
Organization: Robobar Ltd., Perivale, Middx., ENGLAND.
Lines: 19