diff options
Diffstat (limited to 'vms/vms_cli.c')
-rw-r--r-- | vms/vms_cli.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/vms/vms_cli.c b/vms/vms_cli.c index 2f475b11..a9386216 100644 --- a/vms/vms_cli.c +++ b/vms/vms_cli.c @@ -11,21 +11,21 @@ #include <string.h> #endif -extern u_long CLI$PRESENT(const Dsc *); -extern u_long CLI$GET_VALUE(const Dsc *, Dsc *, short *); -extern u_long CLI$DCL_PARSE(const Dsc *, const void *, ...); -extern u_long SYS$CLI(void *, ...); -extern u_long SYS$FILESCAN(const Dsc *, void *, long *); -extern void *LIB$ESTABLISH(u_long (*handler)(void *, void *)); -extern u_long LIB$SIG_TO_RET(void *, void *); /* condition handler */ +extern U_Long CLI$PRESENT(const Dsc *); +extern U_Long CLI$GET_VALUE(const Dsc *, Dsc *, short *); +extern U_Long CLI$DCL_PARSE(const Dsc *, const void *, ...); +extern U_Long sys$cli(void *, ...); +extern U_Long sys$filescan(const Dsc *, void *, long *); +extern void *lib$establish(U_Long (*handler)(void *, void *)); +extern U_Long lib$sig_to_ret(void *, void *); /* condition handler */ /* Cli_Present() - call CLI$PRESENT to determine whether a parameter or */ /* qualifier is present on the [already parsed] command line */ -u_long +U_Long Cli_Present( const char *item ) { Dsc item_dsc; - (void)LIB$ESTABLISH(LIB$SIG_TO_RET); + (void)lib$establish(lib$sig_to_ret); item_dsc.len = strlen(item_dsc.adr = (char *)item); return CLI$PRESENT(&item_dsc); @@ -33,13 +33,13 @@ Cli_Present( const char *item ) /* Cli_Get_Value() - call CLI$GET_VALUE to retreive the value of a */ /* parameter or qualifier from the command line */ -u_long +U_Long Cli_Get_Value( const char *item, char *result, int size ) { Dsc item_dsc, res_dsc; - u_long sts; + U_Long sts; short len = 0; - (void)LIB$ESTABLISH(LIB$SIG_TO_RET); + (void)lib$establish(lib$sig_to_ret); item_dsc.len = strlen(item_dsc.adr = (char *)item); res_dsc.len = size, res_dsc.adr = result; @@ -52,20 +52,20 @@ Cli_Get_Value( const char *item, char *result, int size ) /* retreive the actual command line (which might be */ /* "run prog" or "mcr prog [params]") and then call */ /* CLI$DCL_PARSE to parse it using specified tables */ -u_long +U_Long Cli_Parse_Command( const void *cmd_tables, const char *cmd_verb ) { struct { short len, code; void *adr; } fscn[2]; struct { char rqtype, rqindx, rqflags, rqstat; unsigned :32; Dsc rdesc; unsigned :32; unsigned :32; unsigned :32; } cmd; - u_long sts; + U_Long sts; int ltmp; char longbuf[2600]; - (void)LIB$ESTABLISH(LIB$SIG_TO_RET); + (void)lib$establish(lib$sig_to_ret); memset(&cmd, 0, sizeof cmd); cmd.rqtype = CLI$K_GETCMD; /* command line minus the verb */ - sts = SYS$CLI( &cmd, (void *)0, (void *)0); /* get actual command line */ + sts = sys$cli(&cmd, (void *)0, (void *)0); /* get actual command line */ if (vmswork(sts)) { /* ok => cli available & verb wasn't "RUN" */ /* invoked via symbol => have command line (which might be empty) */ @@ -74,7 +74,7 @@ Cli_Parse_Command( const void *cmd_tables, const char *cmd_verb ) /* need to strip image name from MCR invocation */ memset(fscn, 0, sizeof fscn); fscn[0].code = FSCN$_FILESPEC; /* full file specification */ - (void)SYS$FILESCAN( &cmd.rdesc, fscn, (long *)0); + (void)sys$filescan(&cmd.rdesc, fscn, (long *)0); cmd.rdesc.len -= fscn[0].len; /* shrink size */ cmd.rdesc.adr += fscn[0].len; /* advance ptr */ } |