Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

accidental ampersand

Jun
127
2
lets say I am trying to type: batch1.btm & batch2.btm
but instead I accidentally type: batch1.btm &

My computer goes berserk. opening and closing windows like mad. I can't stop it.

1. Why is this happening?
2. what is the best way to halt?
 
Code:
batch1.btm &
is just a synonym for
Code:
detach batch1.btm

DETACH should report the PID for the new process when it creates it; you can feed that PID to TASKEND to kill it.
 
lets say I am trying to type: batch1.btm & batch2.btm
but instead I accidentally type: batch1.btm &

My computer goes berserk. opening and closing windows like mad. I can't stop it.

1. Why is this happening?
2. what is the best way to halt?
I suspect the windows are those of transient instances of TCC, probably from pipes, or of instances of external programs. "TASKEND /F %_DETACHPID" (or do it manually from TaskMgr) should get rid of most or all of things.

But there's something I don't understand, namely piping in a detached instance. If I DETACH this BTM,
Code:
v:\> type abcd.btm
echo foo | grep foo
a console window for GREP.EXE opens and doesn't close. What's going on there?
 
But there's something I don't understand, namely piping in a detached instance. If I DETACH this BTM,
Code:
v:\> type abcd.btm
echo foo | grep foo
a console window for GREP.EXE opens and doesn't close. What's going on there?

GREP.EXE is an external app, and gets its own console window. There isn't any way to tell Windows that you want child pipe processes to be detached. (Nor can I imagine a situation where you would want to do this -- certainly nobody's brought it up in the last 15 years.)
 
GREP.EXE is an external app, and gets its own console window. There isn't any way to tell Windows that you want child pipe processes to be detached. (Nor can I imagine a situation where you would want to do this -- certainly nobody's brought it up in the last 15 years.)
The window doesn't surprise me. It's the fact that it doesn't close. Does the detached TCC produce standard output that should go to GREP?
 
Back
Top