Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!husc6!mit-eddie!apollo!gaz From: gaz@apollo.COM (Gary Zaidenweber) Newsgroups: comp.sys.apollo Subject: Re: name_$not_found status code Message-ID: <431a2a92.ce45@apollo.COM> Date: 8 May 89 17:25:00 GMT References: <8905041340.AA03449@umix.cc.umich.edu> Organization: Apollo Computer, Chelmsford, Mass. Lines: 42 From article <8905041340.AA03449@umix.cc.umich.edu>, by FERGUSON@TMASL.EXXON.COM: > > I tried to open a mailbox file that doesn't exist today, and received > the status code = 0x800e0007 > When I do an error_$print on this status code, I get the error > name not found from (OS/naming server). Therefore, I tried to > put in a conditional like this: > > if (status.all == name_$not found) { > etc. > > However, the name_$not_found status code in /sys/ins/name.ins.c > is different by one bit. Instead of being 0x800e0007, it's > 0x000e0007, and I don't know why. Obviously, I can kludge my > way around this, but has anyone else noticed it? > > I did an fpat (grep) on all of the /sys/ins/?*.c files as well as > the .pas files, and the status code is not defined anywhere. > Anyone know anything about this? Does the error handler ignore > that first bit or something? > > Thanks, > Scott Ferguson > ferguson@erevax.bitnet > [ status_$t is a variant record (union). The top bit is a boolean called "fail". See base.ins.pas for more info. I can't give you much information on how/why/who causes the "fail" bit to be set, but checking it like this: if ((status.all & 0x7FFFFFFF) == name_$not_found) { etc. would be perfectly valid and would even yield the correct results :-) Please note the bitwise AND (&) rather than a logical and (&&). Also please forgive the pedantic explanation if you didn't need it. -- Gary Zaidenweber | Its 1989: UUCP: umix!apollo!gaz | Do you know where your lawyer is? ARPA: gaz@apollo.COM |