I'm calling system command
system("tftp -m binary 192.168.1.1 -c get myfile > /dev/null") ;
it works fine when tftp server is running but it makes my c program crashed when tftp server is off.
Is there a way to check whether the server is available or not in c source code ?