Article View: comp.sys.ibm.pc.programmer
Article #1312redirection indicated in argc
From: David J. Camp
Date: Fri, 16 Feb 1990 07:38
Date: Fri, 16 Feb 1990 07:38
18 lines
1153 bytes
1153 bytes
I was using Microsoft C, and had a program that used command line
arguments and read the standard input. When I specified:
command arg1 arg2 ... argn-1 < filename
The argc variable reflected the presence of the filename.
i.e. it had the value n+1.
When I specified:
type filename | command arg1 arg2 ... argn-1
it was not indicated, i.e. it had the value n. I think this must
be a compiler bug. -David-
Bitnet: david@wubios.wustl ^ Mr. David J. Camp
Internet: david%wubios@wugate.wustl.edu < * > Box 8067, Biostatistics
uucp: uunet!wugate!wubios!david v 660 South Euclid
Washington University (314) 36-23635 Saint Louis, MO 63110
Technical Details
Message-ID:
<1022@wubios.wustl.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!wuarchive!wubios!davidShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!wuarchive!wubios!david From: david@wubios.wustl.edu (David J. Camp) Newsgroups: comp.sys.ibm.pc.programmer Subject: redirection indicated in argc Message-ID: <1022@wubios.wustl.edu> Date: 16 Feb 90 07:38:07 GMT Sender: david@wubios.wustl.edu (David J. Camp) Reply-To: david@wubios.UUCP (David J. Camp) Organization: Washington University (St. Louis) Lines: 18