Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ENOTTY (errno 25) on system() call with a deamonize binary on SCO Unix 1

Status
Not open for further replies.

desb0

Programmer
Jul 13, 2005
4
CA
Hi,

I try to call in a c binary the following command.

system("pack_it");

where pack_it is a little binary that compress a file.

The trouble is that my binary that call system("pack_it"); is a deamonize binary. So no TTY associated with it.

So system("pack_it); return ENOTTY (errno 25).

So ... HOW THE HELL DO I CALL ANOTHER BINARY WITHIN A DEAMONIZE BINARY?

Thank you ^_^

Bruno
 
Have you tried something like this ?
system("pack_it >&- 2>&- <&-");

Another way is to play with fork() and exec()

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top