From: rsalz@osf.org (Rich Salz)
Subject: Re: error handling in DCE-based applications
Date: 27 Oct 1994 16:26:57 GMT [thread overview]
Message-ID: <38okch$d9u@paperboy.osf.org> (raw)
In-Reply-To: NAYERI.94Oct25100302@slbh13.bln.sel.alcatel.de
In <NAYERI.94Oct25100302@slbh13.bln.sel.alcatel.de> nayeri@bln.sel.alcatel.de writes:
>Together with HP DCE a sample application is shipped called 'phone_db'. The
>application contains the following code for error handling:
...
>This seems to me to be an elegant way to handle errors in an
>uniform way.
No, it's a hack. Trying to handle both DCE status codes and native
system errors (such as errno) is almost guaranteed to not be portable.
However, the following might help:
- Try always calling dce_error_inq_text; if the status param is -1
then it's either not DCE error code or the required message catalog
isn't available.
- If "random_status >>24" is 1 or 2, then it's in the space that DCE
reserves for itself and DFS.
Note that these get you more portable, not truly portable.
Mixing errno-like things and DCE status codes is a mistake.
/r$
prev parent reply other threads:[~1994-10-27 16:26 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
1994-10-25 9:03 error handling in DCE-based applications nader nayeri
1994-10-25 17:21 ` Mustafizur Rahman
1994-10-27 16:26 ` Rich Salz [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox