Sysop: | Amessyroom |
---|---|
Location: | Fayetteville, NC |
Users: | 28 |
Nodes: | 6 (1 / 5) |
Uptime: | 58:47:57 |
Calls: | 424 |
Calls today: | 2 |
Files: | 1,025 |
Messages: | 90,903 |
Posted today: | 1 |
This might be a very simple question but I can't find any reference to
it on the net.
Working in C, how do you get the RMS$_CODE symbol for any given error
number as returned from any operation? I use strerror() to get an interpretation but it does not include said symbol.
exit(rms_return_number); will print it out so I know it must be possible.
On 2025-03-18, Michael Brown <brown_mi@decuserve.org> wrote:
This might be a very simple question but I can't find any reference to
it on the net.
Working in C, how do you get the RMS$_CODE symbol for any given error
number as returned from any operation? I use strerror() to get an
interpretation but it does not include said symbol.
exit(rms_return_number); will print it out so I know it must be possible.
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Simon.
I _think_ what he wants is some kind of translation table between errno values and VMS condition codes. For example, starting with errno of
ESRCH and getting to RMS$_RNF or vice versa. I'm not aware of any such table, and if there were, it wouldn't be a one-to-one mapping.
On 20/3/25 00:04, Simon Clubley wrote:
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Simon.
I'm sorry I'm not with you, I haven't seen any previous answers?
On 19/03/2025 14:06, Michael Brown wrote:
On 20/3/25 00:04, Simon Clubley wrote:
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Simon.
I'm sorry I'm not with you, I haven't seen any previous answers?
I think he was referring to your thread "Error Number to Symbol" which
had a few replies
On 20/3/25 00:04, Simon Clubley wrote:
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Simon.
I'm sorry I'm not with you, I haven't seen any previous answers?
On 20/3/25 00:38, Craig A. Berry wrote:
I _think_ what he wants is some kind of translation table between errno
values and VMS condition codes. For example, starting with errno of
ESRCH and getting to RMS$_RNF or vice versa. I'm not aware of any such
table, and if there were, it wouldn't be a one-to-one mapping.
yes if I get a return status of 98994 I would like to be able to look it
up and get "RMS$_RNF" to output that in my error handling routine.
On 3/19/25 9:29 AM, Michael Brown wrote:
On 20/3/25 00:38, Craig A. Berry wrote:
I _think_ what he wants is some kind of translation table between errno
values and VMS condition codes. For example, starting with errno of
ESRCH and getting to RMS$_RNF or vice versa. I'm not aware of any such >>> table, and if there were, it wouldn't be a one-to-one mapping.
yes if I get a return status of 98994 I would like to be able to look
it up and get "RMS$_RNF" to output that in my error handling routine.
No, I guessed wrong. You are not dealing with errno at all but rather
VMS condition code to message lookup, which, as you've now discovered,
has already been fully answered.
On 3/19/2025 12:08 PM, Craig A. Berry wrote:
On 3/19/25 9:29 AM, Michael Brown wrote:
On 20/3/25 00:38, Craig A. Berry wrote:
I _think_ what he wants is some kind of translation table between errno >>>> values and VMS condition codes. For example, starting with errno of
ESRCH and getting to RMS$_RNF or vice versa. I'm not aware of any such >>>> table, and if there were, it wouldn't be a one-to-one mapping.
yes if I get a return status of 98994 I would like to be able to look
it up and get "RMS$_RNF" to output that in my error handling routine.
No, I guessed wrong. You are not dealing with errno at all but rather
VMS condition code to message lookup, which, as you've now discovered,
has already been fully answered.
I was starting to think that it was about translating from
numeric value to symbolic name, which is a weird one.
$ run moremsgfun
98962 = RMS$_FNF
Arne
This might be a very simple question but I can't find any reference to
it on the net.
Working in C, how do you get the RMS$_CODE symbol for any given error
number as returned from any operation? I use strerror() to get an interpretation but it does not include said symbol.
exit(rms_return_number); will print it out so I know it must be possible.
On 20/3/25 05:20, Arne Vajhøj wrote:
On 3/19/2025 12:08 PM, Craig A. Berry wrote:
On 3/19/25 9:29 AM, Michael Brown wrote:
On 20/3/25 00:38, Craig A. Berry wrote:
I _think_ what he wants is some kind of translation table between
errno
values and VMS condition codes. For example, starting with errno of >>>>> ESRCH and getting to RMS$_RNF or vice versa. I'm not aware of any
such
table, and if there were, it wouldn't be a one-to-one mapping.
yes if I get a return status of 98994 I would like to be able to
look it up and get "RMS$_RNF" to output that in my error handling
routine.
No, I guessed wrong. You are not dealing with errno at all but rather
VMS condition code to message lookup, which, as you've now discovered,
has already been fully answered.
I was starting to think that it was about translating from
numeric value to symbolic name, which is a weird one.
$ run moremsgfun
98962 = RMS$_FNF
This is exactly what I intended with the original post, so this pas
source is very interesting to me.
This is exactly what I intended with the original post, so this pas
source is very interesting to me.
It is just two lib$sys_getmsg calls with flags to get
facility and identity and then it is cross fingers and
hope the symbolic name follow convention of facility$_identity.
Arne
On 20/3/25 09:44, Arne Vajhøj wrote:
This is exactly what I intended with the original post, so this pas
source is very interesting to me.
It is just two lib$sys_getmsg calls with flags to get
facility and identity and then it is cross fingers and
hope the symbolic name follow convention of facility$_identity.
Yes I see, I would have never known about the effect of the flag field
and would have plowed ahead and broken down the default message with
strtok to get what I wanted. This is far more efficient. It will
certainly work for all the RMS return codes so that's mainly what I need.
On 3/19/2025 10:06, Michael Brown wrote:
On 20/3/25 00:04, Simon Clubley wrote:
Can you explain what was missing in the previous answers you received
so the authors of those answers can clarify them if needed ?
Simon.
I'm sorry I'm not with you, I haven't seen any previous answers?
What reader are you using? There are several credible answers to the
thread
you started whose subject is "Error Number to Symbol"