Run bash as a child process in C having same effect as do ssh has

view full story

http://forums.fedoraforum.org – I want to run bash as child process of my C program. Few conditions 1) My program will handle both STDIN and STDOUT of bash. 2) No care about practical use. I have done it but it does not looks like bash. Here is my code Code: #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <pthread.h> #include <sys/wait.h> // for tunneling the data struct tnl {     int in;     int out; }; // for tunneling the data void *do_tnl(void *ptr); int main(int argc,char **argv) {     int p1[2];   & (HowTos)