From: Frank Kardel Date: Sat, 11 Aug 2007 17:19:45 +0000 (+0000) Subject: refclock_parse.c: X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=315c0519a0cdfbdee06bf0035c095d401609e049;p=thirdparty%2Fntp.git refclock_parse.c: remove io binding before io_closeclock() closes the file descriptor bk: 46bdefb1cwTbbz5eOCj5Nk6XqHp_RA --- diff --git a/ntpd/refclock_parse.c b/ntpd/refclock_parse.c index f24c75c5f3..0b0109cf6f 100644 --- a/ntpd/refclock_parse.c +++ b/ntpd/refclock_parse.c @@ -1,15 +1,21 @@ /* - * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.78 2006/12/22 20:08:27 kardel RELEASE_20061222_A + * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp * - * refclock_parse.c,v 4.78 2006/12/22 20:08:27 kardel RELEASE_20061222_A + * refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp * * generic reference clock driver for several DCF/GPS/MSF/... receivers * - * optionally make use of a STREAMS module for input processing where - * available and configured. Currently the STREAMS module - * is only available for Suns running SunOS 4.x and SunOS5.x + * PPS notes: + * On systems that support PPSAPI (RFC2783) PPSAPI is the + * preferred interface. * - * Copyright (c) 1995-2006 by Frank Kardel ntp.org> + * Optionally make use of a STREAMS module for input processing where + * available and configured. This STREAMS module reduces the time + * stamp latency for serial and PPS events. + * Currently the STREAMS module is only available for Suns running + * SunOS 4.x and SunOS5.x. + * + * Copyright (c) 1995-2007 by Frank Kardel ntp.org> * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany * * Redistribution and use in source and binary forms, with or without @@ -182,7 +188,7 @@ #include "ieee754io.h" #include "recvbuff.h" -static char rcsid[] = "refclock_parse.c,v 4.78 2006/12/22 20:08:27 kardel RELEASE_20061222_A"; +static char rcsid[] = "refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp"; /**=========================================================================== ** external interface to ntp mechanism @@ -2633,13 +2639,16 @@ parse_shutdown( } /* - * Tell the I/O module to turn us off. We're history. + * cleanup before leaving this world */ - io_closeclock(&parse->generic->io); - if (parse->binding) PARSE_END(parse); + /* + * Tell the I/O module to turn us off. We're history. + */ + io_closeclock(&parse->generic->io); + free_varlist(parse->kv); NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ @@ -5735,6 +5744,12 @@ int refclock_parse_bs; * History: * * refclock_parse.c,v + * Revision 4.80 2007/08/11 12:06:29 kardel + * update comments wrt/ to PPS + * + * Revision 4.79 2007/08/11 11:52:23 kardel + * - terminate io bindings before io_closeclock() will close our file descriptor + * * Revision 4.78 2006/12/22 20:08:27 kardel * Bug 746 (RFE): add configuration for Expert mouseCLOCK USB v2.0 as mode 19 *