HANNON@PS1.CS.CMU.EDU (Mike Hannon) (10/07/85)
I have a program, written in VAX C, which is an extension of the old WHO
program that came with VMS. I.e., my program, WHOX, reads the UAF for
information about a specified user. The program has an associated message
file, WHOXMSG.MSG, and uses LIB$SIGNAL to signal errors, such as "the user
you specified doesn't exist". The program worked fine under VMS 3.6 and an
experimental version of the C 2.0 compiler. Now with VMS 4.1 and the
released version of C 2.0, the program (a) gets a compile-time warning about
a type conflict and (b) gets a run-time stack dump when LIB$SIGNAL is
invoked.
The variables used to signal the errors all have the prefix MSG_. The
following search shows the use of the variables.
$ search whox.c msg_
globalref unsigned int MSG_INV_UIC;
globalref unsigned int MSG_INV_USR_NAM;
globalref unsigned int MSG_NO_DEV_TYPE;
globalref unsigned int MSG_NONX_USER;
LIB$SIGNAL (&MSG_INV_UIC, 1, &response_dsc);
LIB$SIGNAL (&MSG_INV_USR_NAM, 1, &response_dsc);
LIB$SIGNAL (&MSG_NONX_USER, 1, &response_dsc);
LIB$SIGNAL (&MSG_NO_DEV_TYPE, 1, stat1);
The WHOXMSG file compiles without any error message. Some excerpts:
.FACILITY WHOX,1 /PREFIX=MSG_
.SEVERITY WARNING
NONX_USER <Nonexistent user: !AS!/>/FAO_COUNT=1
.END
Here's the compile-time message; this did not occur with the previous
versions of C/VMS:
$ cc whox
%CC-W-TYPECONFLICT, "unsigned" conflicts with a previous data type in this
declaration; previous data type ignored.
At line number 67 in SYS$USER:[HANNON.ENV.WHOX.V4]WHOX.C;4.
%CC-I-SUMMARY, Completed with 0 error(s), 1 warning(s), and
0 informational messages.
Here's a typical run-time error:
$ run whox
Username or UIC: foobar
%WHOX-W-NONX_USER, Nonexistent user: foobar
%TRACE-W-TRACEBACK, symbolic stack dump follows
module name routine name line rel PC abs PC
WHOX read_one_rec 2777 0000006E 00001FC5
WHOX main 2613 0000013A 00001D3A
Line 2777 is one of the LIB$SIGNAL invocations.
Does anybody know what I'm doing wrong? Thanks.
- Mike
------