[fa.info-vax] lib

info-vax@ucbvax.ARPA (12/21/84)

From: Provan@LLL-MFE.ARPA

One of my programs is behaving badly.  The explaination that describes it
with only one assumption is that Lib$AST_In_Prog is returning >0 even though
it's not called from AST level.  Has anyone else had a similar experience?
It just occured to me as I write this that it could be returning 2 or 4,
for example, instead of 0.  Does anyone know if this is possible?

info-vax@ucbvax.ARPA (12/21/84)

From: Provan@LLL-MFE.ARPA

Allow me to apologize to Lib$AST_In_Prog, as well as all of you for
wasting your time.  While poking around, I found that the program was,
in fact, at AST level at incorrect times, so as far as I know,
Lib$AST_In_Prog was correct at all times.

For the benefit of the group, I did get one response claiming that he
vaguely remembered Lib$AST_In_Prog being generally incorrect, but he
hadn't had his morning coffee yet, so he was probably just dreaming.

info-vax@ucbvax.ARPA (04/19/85)

From: Rudy.Nedved@CMU-CS-A.ARPA

Is there some magic which can be used in connection with LIB$SPAWN
whereby I can specify a command AND an input file and the subprocess
will execute the command and then exit.

If a don't specify an input file....it works but uses the parent
process's sys$input which is unacceptable.

-Rudy

info-vax@ucbvax.ARPA (04/19/85)

From: Gail Rubin <grubin@bbn-spca>

I'm not quite sure if this is what you asked, but you can
specify NLA0: as the input if you don't want it to use
any input. Or, if what you meant was for the command to
take any required input from a particular file of yours,
I thought you could specify both a command and an input file
to do that.

-- Gail Rubin
(grubin@bbn-spca or @bbn-unix)

info-vax@ucbvax.ARPA (04/20/85)

From: Gail Rubin <grubin@bbn-spca>

I think I understand the question now. What we always do when
we have a command that is to take its input from a file is:
instead of passing the command and input file directly to
lib$spawn, we use an intermediary command file. What we then pass
to lib$spawn as the command looks like this (with the quotes):

	$ @SYS$BBN:EXECV3 input_file "original command"

and the command file SYS$BBN:EXECV3 looks like this:

	$ ASSIGN/USER 'P1' SYS$INPUT
	$ 'P2'

We don't bother specifying the input file in the lib$spawn call.

Is this what you need?

This workaround is used in place of calling lib$spawn with the original
command and input file to solve the problem that if the command does not
use all of the data from the input file, DCL tries to execute the rest of
the input file as if it contained commands.

-- Gail Rubin

info-vax@ucbvax.ARPA (04/23/85)

From: Rudy.Nedved@CMU-CS-A.ARPA

Currently I am specifing NLA0: so that when the CLI reads from the
input...it exits. Alas under some conditions, the program or command
I run may want input and if so I would like to send it. If I specify
both the SYS$INPUT parameter and a command....the CLI prompts for the
second command....when I want it to terminate and return the commands
exit status.

-Rudy