Path: utzoo!attcan!uunet!cbmvax!ag From: ag@cbmvax.commodore.com (Keith Gabryelski) Newsgroups: comp.unix.internals Subject: Re: Undocumented Return Codes Message-ID: <15400@cbmvax.commodore.com> Date: 25 Oct 90 20:41:21 GMT References: <1893@necisa.ho.necisa.oz> Reply-To: ag@cbmvax.commodore.com (Keith Gabryelski) Organization: Commodore-Amiga Unix; West Chester, PA Lines: 25 In article <1893@necisa.ho.necisa.oz> boyd@necisa.ho.necisa.oz (Boyd Roberts) writes: >Surely you mean that if you don't know how to handle a specific recovery >(for some unspecified error type) it's still treated as failure? How do you handle undocmented return codes? In the case of close() and Gnu Emacs--aborting or ignoring are both wrong (the data in the file that was written is not up to date). The correct solution would be to warn the user and return upon request. But how do you know this before hand? What is reasonable to expect from a programmer? I system call that returns an error code that is undocumented was documented wrong AND when it does return an odd error IS in wrong. A programmer should not be required to handle such things. All bets are off if umask(2) returns -1 (ENOMEM). Pax, Keith -- ``[...] you twist and turn -- like a twisty turny thing.'' --Boyd Roberts Keith Gabryelski ag@amix.commodore.com