Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!hao!noao!arizona!wendt From: wendt@arizona.edu (Alan Lee Wendt) Newsgroups: comp.lang.c Subject: Re: A better perror() (Was: Re: Accessing argc ...) Message-ID: <1887@megaron.arizona.edu> Date: Thu, 20-Aug-87 19:10:23 EDT Article-I.D.: megaron.1887 Posted: Thu Aug 20 19:10:23 1987 Date-Received: Sat, 22-Aug-87 14:35:47 EDT References: <1478@cullvax.UUCP> Organization: U of Arizona CS Dept, Tucson Lines: 13 > > Another problem with error reporting on Unix is that there's no way > > that I know of to translate open file id's back into filenames. > > Basically, because there is no such translation. You've got an i-node > open, and it may have many names. It could give me back the name I opened it under, or "stdin", "stdout", or "stderr". That would be a lot better than nothing. I currently accomplish this for my own systems by redefining Unix library calls ie "#define open uxopen" and stashing the text string in uxopen. But I would sleep better if I didn't have to do such disgusting things. Alan W.