Skip navigation.
Home
The QNX Community Portal

View topic - Use of system function call in Neutrino

Use of system function call in Neutrino

For discussion of realtime and/or embedded programming.

Use of system function call in Neutrino

Postby jogeshwar » Thu Nov 25, 2010 10:43 am

Hi,

I am using Neutrino 6.4.1 for my development.
I am planning to use shell commands in my C code.
I intend to use the system() function call for the same, but i am not so sure about the return value of the system call.

Any idea if i can use some other function to achieve the same purpose with reliable and deterministic behaviour.

It would also be useful if someone can guide me to source code of system() function call in Neutrino.

Regards,
jogeshwar
jogeshwar
New Member
 
Posts: 1
Joined: Thu Nov 25, 2010 10:38 am

RE: Use of system function call in Neutrino

Postby maschoen » Fri Nov 26, 2010 2:09 am

I'm fairly sure that it returns the return code of the program you start, unless you run the program with an '&'.
You can easily test this.

Otherwise you probably want to look at the spawn family of calls.
maschoen
QNX Master
 
Posts: 2640
Joined: Wed Jun 25, 2003 5:18 pm


Return to Realtime and Embedded

Who is online

Users browsing this forum: No registered users and 2 guests

cron