Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!stanford.edu!unix!ctnews!mitisft!dold From: dold@mitisft.Convergent.COM (Clarence Dold) Newsgroups: comp.unix.questions Subject: Re: errno Message-ID: <2159@mitisft.Convergent.COM> Date: 17 Jun 91 22:31:50 GMT References: <1991Jun17.124318.1384@prl.dec.com> Organization: Unisys Unix Systems Group, San Jose, CA Lines: 15 in article <1991Jun17.124318.1384@prl.dec.com>, boyd@prl.dec.com (Boyd Roberts) says: > In article <2157@mitisft.Convergent.COM>, dold@mitisft.Convergent.COM (Clarence Dold) writes: >> printf("Errno %d: %s\n", want_err, >> want_err <= sys_nerr ? sys_errlist[want_err] : "Out of range" ); > Eh? The bounds of a reasonable errnos lie between 1 and sys_nerr. > `errno == 0' means no error. But sys_errlist[0] does contain a string, so it shouldn't be excluded, unless you especially like to have extra instructions in your code. -- --- Clarence A Dold - dold@tsmiti.Convergent.COM ...pyramid!ctnews!tsmiti!dold