-diff -Naurp ntp-4.2.2p4.orig/ntpd/refclock_nmea.c ntp-4.2.2p4.mash/ntpd/refclock_nmea.c
---- ntp-4.2.2p4.orig/ntpd/refclock_nmea.c 2006-06-06 22:16:53.000000000 +0200
-+++ ntp-4.2.2p4.mash/ntpd/refclock_nmea.c 2006-12-13 16:22:26.000000000 +0100
-@@ -16,6 +16,7 @@
+--- a/ntpd/refclock_nmea.c
++++ b/ntpd/refclock_nmea.c
+@@ -11,6 +11,7 @@
#include <stdio.h>
#include <ctype.h>
#include "ntpd.h"
#include "ntp_io.h"
-@@ -72,6 +72,7 @@
+@@ -72,6 +73,7 @@ extern int async_write(int, const void *
#define RANGEGATE 500000 /* range gate (ns) */
#define LENNMEA 75 /* min timecode length */
/*
* Tables to compute the ddd of year form icky dd/mm timecode. Viva la
-@@ -92,6 +93,7 @@ struct nmeaunit {
+@@ -92,6 +94,7 @@ struct nmeaunit {
pps_params_t pps_params; /* pps parameters */
pps_info_t pps_info; /* last pps data */
pps_handle_t handle; /* pps handlebars */
#endif /* HAVE_PPSAPI */
};
-@@ -140,7 +142,12 @@ nmea_start(
+@@ -140,7 +143,12 @@ nmea_start(
register struct nmeaunit *up;
struct refclockproc *pp;
int fd;
/*
* Open serial port. Use CLK line discipline, if available.
-@@ -225,18 +232,42 @@ nmea_start(
+@@ -225,18 +233,42 @@ nmea_start(
memcpy((char *)&pp->refid, REFID, 4);
up->pollcnt = 2;
gps_send(pp->io.fd,"$PMOTG,RMC,0000*1D\r\n", peer);
return(nmea_ppsapi(peer, 0, 0));
#else
return (1);
-@@ -258,8 +289,10 @@ nmea_shutdown(
+@@ -258,8 +290,10 @@ nmea_shutdown(
pp = peer->procptr;
up = (struct nmeaunit *)pp->unitptr;
#ifdef HAVE_PPSAPI
#endif /* HAVE_PPSAPI */
io_closeclock(&pp->io);
free(up);
-@@ -367,7 +400,7 @@ nmea_pps(
+@@ -367,7 +401,7 @@ nmea_pps(
/*
* Convert the timespec nanoseconds field to ntp l_fp units.
*/