[ntp:questions] "ntpdate" hanging !!

Srikanth K srikanth.k at hp.com
Mon Mar 7 10:06:31 UTC 2005


Hello ,

I notice a hang when i run the below mentioned program in a hp-ux 11.11 
machine. The "ntpdate" binary which i am using in the program is taken 
from "ntp-stable-4.2.0a-20040617" of the open ntp source.

/* program starts here */
#include <signal.h>
#include <unistd.h>

main()
{

long oldmask, newmask;

oldmask = sigblock(0);
sigblock(sigmask(SIGALRM));

system("/usr/sbin/ntpdate -q <timeserver-ip>");

sigsetmask(oldmask);

}
/* program ends here */


Is it a bug in "ntpdate" binary? If so, is there any fix available for it?


Thanks in Advance,
-Srikanth K.




More information about the questions mailing list