Article View: comp.unix
Article #751system command
From: Gaurav Singh
Date: Tue, 27 Jun 1995 00:00
Date: Tue, 27 Jun 1995 00:00
31 lines
1492 bytes
1492 bytes
Hi,
I am trying to execute the "system" command to execute an application
(executable program).
However the system command does not work if the name of the application has been
aliased.
e.g: $ alias test ps
$ test
(this works)
however system("test"); in a c-program does not work.
sh: test: not found
I wonder if there is a way to force the system command to take into
account the aliases, or is there a more efficient way to invoke an application
from a c-program.
pl reply to this news group or to gsingh@isi.edu
thanks a ton
Gaurav
Technical Details
Message-ID:
<3sprhr$6g6@venera.isi.edu>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f8c9b,f653ab8f84d6a686,start X-Google-Attributes: gidf8c9b,public X-Google-Thread: fc89c,f653ab8f84d6a686,start X-Google-Attributes: gidfc89c,public X-Google-Thread: f72b0,f653ab8f84d6a686,start X-Google-Attributes: gidf72b0,public X-Google-Thread: 1012a6,f653ab8f84d6a686,start X-Google-Attributes: gid1012a6,public X-Google-Thread: 10183f,f653ab8f84d6a686,start X-Google-Attributes: gid10183f,public X-Google-Thread: 10f717,f653ab8f84d6a686,start X-Google-Attributes: gid10f717,public From: gsingh@isi.edu (Gaurav Singh) Subject: system command Date: 1995/06/27 Message-ID: <3sprhr$6g6@venera.isi.edu> X-Deja-AN: 105130677 distribution: world organization: USC Information Sciences Institute keywords: system newsgroups: comp.unix,ca.unix,comp.unix.misc,comp.unix.programmer,comp.unix.questions,comp.unix.shell